Skip to content

Commit

Permalink
Collaborators
Browse files Browse the repository at this point in the history
  • Loading branch information
odeimaiz committed Nov 20, 2024
1 parent 1b06549 commit 11c77f9
Showing 1 changed file with 11 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -412,14 +412,18 @@ qx.Class.define("osparc.share.Collaborators", {
if (Object.prototype.hasOwnProperty.call(this.__collaborators, gid)) {
const collab = this.__collaborators[gid];
// Do not override collaborator object
const collaborator = osparc.utils.Utils.deepCloneObject(collab);
if ("first_name" in collaborator) {
const collaborator = {
"gid": collab.getGroupId(),
"thumbnail": collab.getThumbnail(),
};
if ("getUserId" in collab) {
// user
collaborator["thumbnail"] = collaborator.getThumbnail();
collaborator["name"] = collaborator.getLabel();
} else if (everyoneGIds.includes(parseInt(gid))) {
// everyone product or everyone
if (collaborator["thumbnail"] === null) {
collaborator["name"] = collab.getLabel();
collaborator["login"] = collab.getLogin();
} else {
collaborator["label"] = collab.getLabel();
collaborator["description"] = collab.getDescription();
if (everyoneGIds.includes(parseInt(gid))) {
collaborator["thumbnail"] = "@FontAwesome5Solid/globe/32";
}
}
Expand Down

0 comments on commit 11c77f9

Please sign in to comment.