Keep only one getPadMetadata in outer

This commit is contained in:
yflory
2019-09-09 14:46:50 +02:00
parent bb0365622b
commit 84249a92b5
4 changed files with 29 additions and 51 deletions

View File

@@ -759,7 +759,6 @@ define([
pad.onMetadataEvent = Util.mkEvent();
pad.getPadMetadata = function (data, cb) {
postMessage('GET_PAD_METADATA', data, cb);
};
pad.requestAccess = function (data, cb) {
@@ -773,10 +772,7 @@ define([
postMessage('SET_PAD_METADATA', data, cb);
};
common.getPadMetadata = function (data, cb) {
common.anonRpcMsg('GET_METADATA', data.channel, function (err, obj) {
if (err) { return void cb({error: err}); }
cb(obj && obj[0]);
});
postMessage('GET_PAD_METADATA', data, cb);
};
common.changePadPassword = function (Crypt, Crypto, href, newPassword, edPublic, cb) {