Andrey Shovkoplyas 2017-05-08 18:48:24 +03:00 committed by Roman Volosovskyi
parent 0df5a59e87
commit 6433676f51
1 changed files with 7 additions and 6 deletions

View File

@ -272,9 +272,9 @@
(status/call-function! (status/call-function!
{:chat-id chat-id {:chat-id chat-id
:function :init}))] :function :init}))]
(dispatch [:load-requests! chat-id]) (dispatch [:load-requests! chat-id])
;; todo rewrite this. temporary fix for https://github.com/status-im/status-react/issues/607 ;; todo rewrite this. temporary fix for https://github.com/status-im/status-react/issues/607
#_(dispatch [:load-commands! chat-id]) #_(dispatch [:load-commands! chat-id])
(if-not commands-loaded? (if-not commands-loaded?
(dispatch [:load-commands! chat-id call-init-command]) (dispatch [:load-commands! chat-id call-init-command])
(do (do
@ -389,10 +389,11 @@
(defn delete-chat! (defn delete-chat!
[_ [_ chat-id]] [_ [_ chat-id]]
(let [{:keys [debug?]} (chats/get-by-id chat-id)] (let [{:keys [debug? group-chat]} (chats/get-by-id chat-id)]
(if debug? (when group-chat
(chats/delete chat-id) (if debug?
(chats/set-inactive chat-id)))) (chats/delete chat-id)
(chats/set-inactive chat-id)))))
(defn remove-pending-messages! (defn remove-pending-messages!
[_ [_ chat-id]] [_ [_ chat-id]]