Redis takes seconds, not milliseconds

This commit is contained in:
Ben Gotow 2016-06-30 13:28:26 -07:00
parent 3c2b8bcb15
commit 65a6ea4546

View file

@ -51,7 +51,7 @@ const markAccountIsActive = (accountId) => {
const client = PubsubConnector.broadcastClient(); const client = PubsubConnector.broadcastClient();
const key = ACTIVE_KEY_FOR(accountId); const key = ACTIVE_KEY_FOR(accountId);
client.incrAsync(key).then((val) => { client.incrAsync(key).then((val) => {
client.expireAsync(key, 5 * 60 * 1000); // 5 min client.expireAsync(key, 5 * 60); // 5 min in seconds
if (val === 1) { if (val === 1) {
PubsubConnector.notifyAccount(accountId, { PubsubConnector.notifyAccount(accountId, {
type: MessageTypes.ACCOUNT_UPDATED, type: MessageTypes.ACCOUNT_UPDATED,