Trigger an onReady() method when the user's pad is fully synced (the history is loaded)

This commit is contained in:
Yann Flory
2016-03-16 14:00:14 +01:00
parent eca4ec699c
commit e77d85bc82
4 changed files with 32 additions and 20 deletions

View File

@@ -97,6 +97,7 @@ let handleMessage = function (ctx, user, msg) {
getHistory(ctx, parsed[1], function (msg) {
sendMsg(ctx, user, [0, HISTORY_KEEPER_ID, 'MSG', user.id, JSON.stringify(msg)]);
});
sendMsg(ctx, user, [0, HISTORY_KEEPER_ID, 'MSG', user.id, 0]);
}
return;
}