Fix a truly silly mistake in rpc.js and make the pad-not-pinned message get removed if a registered user joins

This commit is contained in:
Caleb James DeLisle
2017-12-08 14:46:32 +01:00
parent 008b2cc67e
commit 7a09bf43eb
2 changed files with 15 additions and 5 deletions

5
rpc.js
View File

@@ -540,9 +540,8 @@ var addPinned = function (
{
Env.evPinnedPadsReady.reg(() => {
channelList.forEach((c) => {
const x = Env.pinnedPads[c];
if (!x) { return; }
delete x[publicKey];
const x = Env.pinnedPads[c] = Env.pinnedPads[c] || {};
x[publicKey] = 1;
});
cb();
});