don't try to decrypt nothing

This commit is contained in:
ansuz
2017-05-12 16:26:51 +02:00
parent 69e933dd17
commit 4c4c21342d

View File

@@ -180,6 +180,10 @@ define([
var cryptKey = secret.keys && secret.keys.fileKeyStr;
var key = Nacl.util.decodeBase64(cryptKey);
if (!u8 || !u8.length) {
return void Cryptpad.errorLoadingScreen(e);
}
FileCrypto.decrypt(u8, key, function (e, data) {
if (e) {
Cryptpad.removeLoadingScreen();