remove an XXX note, log when restoring docs by admin rpc

pull/1/head
ansuz 4 years ago
parent 255527cc23
commit 4c7f7e271e

@ -188,10 +188,21 @@ var restoreArchivedDocument = function (Env, Server, cb, data) {
switch (id.length) {
case 32:
return void Env.msgStore.restoreArchivedChannel(id, cb);
return void Env.msgStore.restoreArchivedChannel(id, Util.both(cb, function (err) {
Env.Log.info("RESTORATION_CHANNEL_BY_ADMIN_RPC", {
id: id,
status: err? String(err): 'SUCCESS',
});
}));
case 48:
// Env.blobStore.restore.proof(userSafekey, id, cb) // XXX ....
return void Env.blobStore.restore.blob(id, cb);
// FIXME this does not yet restore blob ownership
// Env.blobStore.restore.proof(userSafekey, id, cb)
return void Env.blobStore.restore.blob(id, Util.both(cb, function (err) {
Env.Log.info("RESTORATION_BLOB_BY_ADMIN_RPC", {
id: id,
status: err? String(err): 'SUCCESS',
});
}));
default:
return void cb("INVALID_ID_LENGTH");
}

Loading…
Cancel
Save