From 84a0125260213fc1bb535ef40fa733b26f6805ea Mon Sep 17 00:00:00 2001 From: Ben Gotow Date: Tue, 12 Jan 2016 15:08:56 -0800 Subject: [PATCH] fix(accounts): Load accounts before adding a new one --- src/flux/stores/account-store.coffee | 1 + 1 file changed, 1 insertion(+) diff --git a/src/flux/stores/account-store.coffee b/src/flux/stores/account-store.coffee index 549455c31..2e5eb72fa 100644 --- a/src/flux/stores/account-store.coffee +++ b/src/flux/stores/account-store.coffee @@ -129,6 +129,7 @@ class AccountStore console.log JSON.stringify(json) throw new Error("Returned account data is invalid") return if @_tokens[json.id] + @_load() @_tokens[json.id] = json.auth_token @_accounts.push((new Account).fromJSON(json)) @_save()