Skip to content

Commit 82a9278

Browse files
committed
minors
1 parent f58f4c4 commit 82a9278

File tree

1 file changed

+5
-3
lines changed
  • services/static-webserver/client/source/class/osparc/dashboard

1 file changed

+5
-3
lines changed

services/static-webserver/client/source/class/osparc/dashboard/CardBase.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,8 @@ qx.Class.define("osparc.dashboard.CardBase", {
170170

171171
// Tooltip
172172
const canIWrite = osparc.data.model.Study.canIWrite(accessRights);
173-
if (gids.length === 0) {
173+
const myGroupId = groupsStore.getMyGroupId();
174+
if (gids.length === 0 || (gids.length === 1 && gids[0] === myGroupId)) {
174175
if (canIWrite) {
175176
shareIcon.set({
176177
toolTipText: qx.locale.Manager.tr("Share")
@@ -200,7 +201,6 @@ qx.Class.define("osparc.dashboard.CardBase", {
200201

201202
// once the groups were removed, the remaining group ids are users' primary groups ids
202203
const usersStore = osparc.store.Users.getInstance();
203-
const myGroupId = groupsStore.getMyGroupId();
204204
for (let i=0; i<gids.length; i++) {
205205
const gid = gids[i];
206206
if (myGroupId !== gid) {
@@ -225,7 +225,9 @@ qx.Class.define("osparc.dashboard.CardBase", {
225225
}
226226
}
227227
const hintText = sharedGrpLabels.join("<br>");
228-
hint.setText(hintText)
228+
if (hintText) {
229+
hint.setText(hintText)
230+
}
229231
}
230232
}, this);
231233
shareIcon.addListener("mouseout", () => hint.exclude(), this);

0 commit comments

Comments
 (0)