diff options
author | Vincent Petry <pvince81@owncloud.com> | 2013-10-17 21:04:18 +0200 |
---|---|---|
committer | Vincent Petry <pvince81@owncloud.com> | 2013-10-17 21:04:18 +0200 |
commit | 41c6c44221177da4458f982bb13a5c7a6f90ff8e (patch) | |
tree | 549c9a5992f4f247ee2d311665863e2b2664749f /apps/files_versions | |
parent | 76be7cd1ac54a8f4a5707c7a50eee106383aa51d (diff) | |
download | nextcloud-server-41c6c44221177da4458f982bb13a5c7a6f90ff8e.tar.gz nextcloud-server-41c6c44221177da4458f982bb13a5c7a6f90ff8e.zip |
Disable versions app JS in public mode
Since the version JS code isn't used in public link mode, disable it to
prevent Chrome freezing bugs due to the t() call being synchronous.
Fixes #4545
Diffstat (limited to 'apps/files_versions')
-rw-r--r-- | apps/files_versions/js/versions.js | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/apps/files_versions/js/versions.js b/apps/files_versions/js/versions.js index 3f56a3eb698..d118456d62e 100644 --- a/apps/files_versions/js/versions.js +++ b/apps/files_versions/js/versions.js @@ -1,5 +1,12 @@ $(document).ready(function(){ + if ($('#isPublic').val()){ + // no versions actions in public mode + // beware of https://github.com/owncloud/core/issues/4545 + // as enabling this might hang Chrome + return; + } + if (typeof FileActions !== 'undefined') { // Add versions button to 'files/index.php' FileActions.register( |