From e65034e4bca9abb9f400d943077814a099ba9eb3 Mon Sep 17 00:00:00 2001 From: Vincent Petry Date: Thu, 2 Jul 2015 14:56:33 +0200 Subject: [PATCH] Do not register JS share plugin if core sharing API is disabled --- apps/files_sharing/js/share.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/apps/files_sharing/js/share.js b/apps/files_sharing/js/share.js index 11c3170c2f0..c754ebdbae9 100644 --- a/apps/files_sharing/js/share.js +++ b/apps/files_sharing/js/share.js @@ -25,6 +25,10 @@ * @param {OCA.Files.FileList} fileList file list to be extended */ attach: function(fileList) { + // core sharing is disabled/not loaded + if (!OC.Share) { + return; + } if (fileList.id === 'trashbin' || fileList.id === 'files.public') { return; }