Fix mute access requests when the pad is not in your drive
parent
a88ce23d55
commit
94622fc34b
|
@ -1053,6 +1053,7 @@ define([
|
|||
spinner.hide();
|
||||
var text = err === "INSUFFICIENT_PERMISSIONS" ? Messages.fm_forbidden
|
||||
: Messages.error;
|
||||
console.error(err);
|
||||
return void UI.warn(text);
|
||||
}
|
||||
spinner.done();
|
||||
|
|
|
@ -845,7 +845,7 @@ define([
|
|||
var metadata = data.metadata;
|
||||
var add = data.add;
|
||||
var _secret = secret;
|
||||
if (metadata && (metadata.href || metadata.roHref)) {
|
||||
if (metadata && (metadata.href || metadata.roHref) && !metadata.fakeHref) {
|
||||
var _parsed = Utils.Hash.parsePadUrl(metadata.href || metadata.roHref);
|
||||
_secret = Utils.Hash.getSecrets(_parsed.type, _parsed.hash, metadata.password);
|
||||
}
|
||||
|
@ -855,7 +855,8 @@ define([
|
|||
var crypto = Crypto.createEncryptor(_secret.keys);
|
||||
nThen(function (waitFor) {
|
||||
// If we already have metadata, use it, otherwise, try to get it
|
||||
if (metadata) { return; }
|
||||
console.error(metadata);
|
||||
if (metadata && metadata.owners) { return; }
|
||||
|
||||
Cryptpad.getPadMetadata({
|
||||
channel: secret.channel
|
||||
|
|
Loading…
Reference in New Issue