summaryrefslogtreecommitdiffstats
path: root/apps/files_sharing
diff options
context:
space:
mode:
authorRoeland Jago Douma <rullzer@users.noreply.github.com>2018-08-16 08:32:19 +0200
committerGitHub <noreply@github.com>2018-08-16 08:32:19 +0200
commit2b5ec3755e9522d06215c6762c3458230abd4fe3 (patch)
tree5eb7ea0eba73356e0b4f4fe6166a4a37db30b3f6 /apps/files_sharing
parentb0af604d0eaf2816f2f1914109168631a616cdbe (diff)
parent5647f85a3cc88e8b650164d56839448abb5e0229 (diff)
downloadnextcloud-server-2b5ec3755e9522d06215c6762c3458230abd4fe3.tar.gz
nextcloud-server-2b5ec3755e9522d06215c6762c3458230abd4fe3.zip
Merge pull request #10692 from nextcloud/deleted-share-remove-actions
Do not show action menu if no actions are available
Diffstat (limited to 'apps/files_sharing')
-rw-r--r--apps/files_sharing/js/share.js8
1 files changed, 5 insertions, 3 deletions
diff --git a/apps/files_sharing/js/share.js b/apps/files_sharing/js/share.js
index 0f8dc58a85e..68529fd882f 100644
--- a/apps/files_sharing/js/share.js
+++ b/apps/files_sharing/js/share.js
@@ -42,14 +42,16 @@
var fileActions = fileList.fileActions;
var oldCreateRow = fileList._createRow;
fileList._createRow = function(fileData) {
+
+ var tr = oldCreateRow.apply(this, arguments);
+ var sharePermissions = OCA.Sharing.Util.getSharePermissions(fileData);
if (fileData.permissions === 0) {
// no permission, disabling sidebar
+ delete fileActions.actions.all.Comment;
delete fileActions.actions.all.Details;
+ delete fileActions.actions.all.Goto;
}
-
- var tr = oldCreateRow.apply(this, arguments);
- var sharePermissions = OCA.Sharing.Util.getSharePermissions(fileData);
tr.attr('data-share-permissions', sharePermissions);
if (fileData.shareOwner) {
tr.attr('data-share-owner', fileData.shareOwner);