This commit is contained in:
Roman Volosovskyi 2016-12-01 17:32:11 +02:00
parent 14477b4921
commit 0916cc6119
2 changed files with 9 additions and 3 deletions

View File

@ -273,7 +273,9 @@
(defn init-chat
([db] (init-chat db nil))
([{:keys [messages current-chat-id] :as db} _]
(assoc-in db [:chats current-chat-id :messages] messages)))
(-> db
(assoc-in [:chats current-chat-id :messages] messages)
(dissoc :messages))))
(defn load-commands!
[{:keys [current-chat-id]}]

View File

@ -56,8 +56,12 @@
(register-handler :initialize-account-db
(fn [db _]
(assoc db :current-chat-id console-chat-id
:edit-mode nil)))
(-> db
(assoc :current-chat-id console-chat-id)
(dissoc :edit-mode
:transactions
:transactions-queue
:new-contact-identity))))
(register-handler :initialize-account
(u/side-effect!