From 03e690b0bc7a3927072ce1d33b6c092d962eb99f Mon Sep 17 00:00:00 2001 From: yflory Date: Tue, 19 Jan 2021 15:14:19 +0100 Subject: [PATCH] lint compliance --- www/common/cryptpad-common.js | 1 - www/common/outer/async-store.js | 4 ++-- www/settings/inner.js | 6 +++--- 3 files changed, 5 insertions(+), 6 deletions(-) diff --git a/www/common/cryptpad-common.js b/www/common/cryptpad-common.js index 22875299d..e33c5f429 100644 --- a/www/common/cryptpad-common.js +++ b/www/common/cryptpad-common.js @@ -990,7 +990,6 @@ define([ }; window.addEventListener('storage', function (e) { if (e.key !== 'CRYPTPAD_STORE|disableCache') { return; } - var o = e.oldValue; var n = e.newValue; if (n) { Cache.disable(); diff --git a/www/common/outer/async-store.js b/www/common/outer/async-store.js index 3dbc08258..4970f041e 100644 --- a/www/common/outer/async-store.js +++ b/www/common/outer/async-store.js @@ -2943,10 +2943,10 @@ define([ var inactiveTime = (+new Date()) - CACHE_MAX_AGE * (24 * 3600 * 1000); Cache.getKeys(function (err, keys) { if (err) { return void console.error(err); } - var next = function (cb) { + var next = function () { if (!keys.length) { return; } var key = keys.pop(); - var value = Cache.getTime(key, function (err, atime) { + Cache.getTime(key, function (err, atime) { if (err) { return void next(); } if (!atime || atime < inactiveTime) { Cache.clearChannel(key, next()); diff --git a/www/settings/inner.js b/www/settings/inner.js index 7d175cab6..9115d0f87 100644 --- a/www/settings/inner.js +++ b/www/settings/inner.js @@ -365,7 +365,7 @@ define([ Messages.settings_cacheHint = "CryptPad stores parts of your documents in your browser's memory in order to save network usage and improve loading times. The documents stored in cache can then be loaded faster the next time you visit them. You can disable the cache if your device doesn't have a lot of free storage space. For security reasons, the cache is always cleared when you log out, but you can clear it manually if you want to reclaim storage space on your machine."; Messages.settings_cacheCheckbox = "Enable cache on this device"; Messages.settings_cacheButton = "Clear existing cache"; - makeBlock('cache', function (cb, $div) { + makeBlock('cache', function (cb) { var store = window.cryptpadStore; var $cbox = $(UI.createCheckbox('cp-settings-cache', @@ -401,9 +401,9 @@ define([ UI.confirmButton(button, { classes: 'btn-danger' }, function () { - spinner.spin(); + spinner2.spin(); sframeChan.query('Q_CLEAR_CACHE', null, function() { - spinner.done(); + spinner2.done(); }); });