Only do regular polling of storage statistics if session_keepalive is enabled

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl 2020-03-16 15:59:41 +01:00 committed by backportbot[bot]
parent ef515358ef
commit dca0f7e760

View file

@ -289,7 +289,7 @@
setTimeout(Files.displayStorageWarnings, 100);
// 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
var func = _.bind(OCA.Files.App.fileList.updateStorageStatistics, OCA.Files.App.fileList);
var updateStorageStatisticsInterval = 5*60*1000;