|
|
@ -748,24 +748,28 @@ define([
|
|
|
|
var me = roster[userData.curvePublic] || {};
|
|
|
|
var me = roster[userData.curvePublic] || {};
|
|
|
|
var owner = Object.keys(roster).filter(function (k) {
|
|
|
|
var owner = Object.keys(roster).filter(function (k) {
|
|
|
|
if (roster[k].pending) { return; }
|
|
|
|
if (roster[k].pending) { return; }
|
|
|
|
|
|
|
|
roster[k].curvePublic = k;
|
|
|
|
return roster[k].role === "OWNER" || roster[k].pendingOwner;
|
|
|
|
return roster[k].role === "OWNER" || roster[k].pendingOwner;
|
|
|
|
}).map(function (k) {
|
|
|
|
}).map(function (k) {
|
|
|
|
return makeMember(common, roster[k], me, roster);
|
|
|
|
return makeMember(common, roster[k], me, roster);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
var admins = Object.keys(roster).filter(function (k) {
|
|
|
|
var admins = Object.keys(roster).filter(function (k) {
|
|
|
|
if (roster[k].pending) { return; }
|
|
|
|
if (roster[k].pending) { return; }
|
|
|
|
|
|
|
|
roster[k].curvePublic = k;
|
|
|
|
return roster[k].role === "ADMIN";
|
|
|
|
return roster[k].role === "ADMIN";
|
|
|
|
}).map(function (k) {
|
|
|
|
}).map(function (k) {
|
|
|
|
return makeMember(common, roster[k], me);
|
|
|
|
return makeMember(common, roster[k], me);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
var members = Object.keys(roster).filter(function (k) {
|
|
|
|
var members = Object.keys(roster).filter(function (k) {
|
|
|
|
if (roster[k].pending) { return; }
|
|
|
|
if (roster[k].pending) { return; }
|
|
|
|
|
|
|
|
roster[k].curvePublic = k;
|
|
|
|
return roster[k].role === "MEMBER" || !roster[k].role;
|
|
|
|
return roster[k].role === "MEMBER" || !roster[k].role;
|
|
|
|
}).map(function (k) {
|
|
|
|
}).map(function (k) {
|
|
|
|
return makeMember(common, roster[k], me);
|
|
|
|
return makeMember(common, roster[k], me);
|
|
|
|
});
|
|
|
|
});
|
|
|
|
var viewers = Object.keys(roster).filter(function (k) {
|
|
|
|
var viewers = Object.keys(roster).filter(function (k) {
|
|
|
|
if (roster[k].pending) { return; }
|
|
|
|
if (roster[k].pending) { return; }
|
|
|
|
|
|
|
|
roster[k].curvePublic = k;
|
|
|
|
return roster[k].role === "VIEWER";
|
|
|
|
return roster[k].role === "VIEWER";
|
|
|
|
}).map(function (k) {
|
|
|
|
}).map(function (k) {
|
|
|
|
return makeMember(common, roster[k], me);
|
|
|
|
return makeMember(common, roster[k], me);
|
|
|
@ -773,6 +777,7 @@ define([
|
|
|
|
var pending = Object.keys(roster).filter(function (k) {
|
|
|
|
var pending = Object.keys(roster).filter(function (k) {
|
|
|
|
if (!roster[k].pending) { return; }
|
|
|
|
if (!roster[k].pending) { return; }
|
|
|
|
if (roster[k].inviteChannel) { return; }
|
|
|
|
if (roster[k].inviteChannel) { return; }
|
|
|
|
|
|
|
|
roster[k].curvePublic = k;
|
|
|
|
return roster[k].role === "MEMBER" || roster[k].role === "VIEWER" || !roster[k].role;
|
|
|
|
return roster[k].role === "MEMBER" || roster[k].role === "VIEWER" || !roster[k].role;
|
|
|
|
}).map(function (k) {
|
|
|
|
}).map(function (k) {
|
|
|
|
return makeMember(common, roster[k], me);
|
|
|
|
return makeMember(common, roster[k], me);
|
|
|
@ -780,6 +785,7 @@ define([
|
|
|
|
var links = Object.keys(roster).filter(function (k) {
|
|
|
|
var links = Object.keys(roster).filter(function (k) {
|
|
|
|
if (!roster[k].pending) { return; }
|
|
|
|
if (!roster[k].pending) { return; }
|
|
|
|
if (!roster[k].inviteChannel) { return; }
|
|
|
|
if (!roster[k].inviteChannel) { return; }
|
|
|
|
|
|
|
|
roster[k].curvePublic = k;
|
|
|
|
return roster[k].role === "VIEWER" || !roster[k].role;
|
|
|
|
return roster[k].role === "VIEWER" || !roster[k].role;
|
|
|
|
}).map(function (k) {
|
|
|
|
}).map(function (k) {
|
|
|
|
return makeMember(common, roster[k], me);
|
|
|
|
return makeMember(common, roster[k], me);
|
|
|
|