Chat commands fix
This commit is contained in:
parent
0d55009388
commit
4e932d9ae8
|
@ -206,8 +206,10 @@
|
|||
chats
|
||||
(->> loaded-chats
|
||||
(map (fn [{:keys [chat-id] :as chat}]
|
||||
(let [last-message (messages/get-last-message chat-id)]
|
||||
[chat-id (assoc chat :last-message last-message)])))
|
||||
(let [last-message (messages/get-last-message chat-id)
|
||||
prev-chat (get chats chat-id)
|
||||
new-chat (assoc chat :last-message last-message)]
|
||||
[chat-id (merge prev-chat new-chat)])))
|
||||
(into (priority-map-by compare-chats))))]
|
||||
|
||||
(-> db
|
||||
|
|
|
@ -177,7 +177,8 @@
|
|||
show-emoji? [:chat-ui-props :show-emoji?]
|
||||
layout-height [:get :layout-height]
|
||||
input-text [:chat :input-text]]
|
||||
{:component-did-mount #(dispatch [:check-autorun])
|
||||
{:component-did-mount #(do (dispatch [:check-autorun])
|
||||
(dispatch [:update-suggestions]))
|
||||
:component-will-unmount #(dispatch [:set-chat-ui-props {:show-emoji? false}])}
|
||||
[view {:style st/chat-view
|
||||
:on-layout (fn [event]
|
||||
|
|
Loading…
Reference in New Issue