diff options
Diffstat (limited to 'apps/files/js/fileinfomodel.js')
-rw-r--r-- | apps/files/js/fileinfomodel.js | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/apps/files/js/fileinfomodel.js b/apps/files/js/fileinfomodel.js index 83a8c62592b..79575109656 100644 --- a/apps/files/js/fileinfomodel.js +++ b/apps/files/js/fileinfomodel.js @@ -126,7 +126,18 @@ }); return deferred.promise(); - } + }, + + canDownload: function() { + for (const i in this.attributes.shareAttributes) { + const attr = this.attributes.shareAttributes[i] + if (attr.scope === 'permissions' && attr.key === 'download') { + return attr.enabled + } + } + + return true + }, }); if (!OCA.Files) { |