From a79d9d3e666ce3c864cb62f31c8a4790d14d711a Mon Sep 17 00:00:00 2001 From: yflory Date: Wed, 19 Jul 2017 11:36:00 +0200 Subject: [PATCH] Make CryptDrive fast again --- www/common/userObject.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/www/common/userObject.js b/www/common/userObject.js index 7a0dba83c..6b4a31bbe 100644 --- a/www/common/userObject.js +++ b/www/common/userObject.js @@ -990,12 +990,12 @@ define([ ['userid', 'previewMode'].forEach(function (attr) { var key = parsed.hash + '.' + attr; var key2 = parsed.hash.slice(0,-1) + '.' + attr;// old pads not ending with / - if (files[key] || files[key2]) { + if (typeof(files[key]) !== "undefined" || typeof(files[key2]) !== "undefined") { debug("Migrating pad attribute", attr, "for pad", id); el[attr] = files[key] || files[key2]; + delete files[key]; + delete files[key2]; } - delete files[key]; - delete files[key2]; }); // Migration done };