Make CryptDrive fast again

pull/1/head
yflory 7 years ago
parent 1dc98dcff1
commit 5ce49af57b

@ -990,12 +990,12 @@ define([
['userid', 'previewMode'].forEach(function (attr) { ['userid', 'previewMode'].forEach(function (attr) {
var key = parsed.hash + '.' + attr; var key = parsed.hash + '.' + attr;
var key2 = parsed.hash.slice(0,-1) + '.' + attr;// old pads not ending with / 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); debug("Migrating pad attribute", attr, "for pad", id);
el[attr] = files[key] || files[key2]; el[attr] = files[key] || files[key2];
delete files[key];
delete files[key2];
} }
delete files[key];
delete files[key2];
}); });
// Migration done // Migration done
}; };

Loading…
Cancel
Save