Merge pull request #19987 from nextcloud/bugfix/noid/disable-storage-stats-without-session_keepalive

Only do regular polling of storage statistics if session_keepalive is enabled
This commit is contained in:
Roeland Jago Douma 2020-03-17 15:06:47 +01:00 committed by GitHub
commit 11341e6c24
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -291,7 +291,7 @@
setTimeout(Files.displayStorageWarnings, 100); setTimeout(Files.displayStorageWarnings, 100);
// only possible at the moment if user is logged in or the files app is loaded // only possible at the moment if user is logged in or the files app is loaded
if (OC.currentUser && OCA.Files.App) { if (OC.currentUser && OCA.Files.App && OC.config.session_keepalive) {
// start on load - we ask the server every 5 minutes // start on load - we ask the server every 5 minutes
var func = _.bind(OCA.Files.App.fileList.updateStorageStatistics, OCA.Files.App.fileList); var func = _.bind(OCA.Files.App.fileList.updateStorageStatistics, OCA.Files.App.fileList);
var updateStorageStatisticsInterval = 5*60*1000; var updateStorageStatisticsInterval = 5*60*1000;