fix #1173
This commit is contained in:
parent
e333c12d35
commit
1010dedca9
|
@ -271,7 +271,7 @@
|
||||||
|
|
||||||
(defn add-new-contact [db [_ {:keys [whisper-identity] :as contact}]]
|
(defn add-new-contact [db [_ {:keys [whisper-identity] :as contact}]]
|
||||||
(-> db
|
(-> db
|
||||||
(update :contacts assoc whisper-identity contact)
|
(update-in [:contacts whisper-identity] merge contact)
|
||||||
(assoc :new-contact-identity "")))
|
(assoc :new-contact-identity "")))
|
||||||
|
|
||||||
(register-handler :add-new-contact
|
(register-handler :add-new-contact
|
||||||
|
@ -297,7 +297,8 @@
|
||||||
(let [contact (if-let [contact-info (get-in chats [chat-id :contact-info])]
|
(let [contact (if-let [contact-info (get-in chats [chat-id :contact-info])]
|
||||||
(read-string contact-info)
|
(read-string contact-info)
|
||||||
(assoc (get contacts chat-id) :pending? false))
|
(assoc (get contacts chat-id) :pending? false))
|
||||||
contact' (assoc contact :address (public-key->address chat-id))]
|
contact' (assoc contact :address (public-key->address chat-id)
|
||||||
|
:pending? false)]
|
||||||
(dispatch [::prepare-contact contact'])
|
(dispatch [::prepare-contact contact'])
|
||||||
(dispatch [:watch-contact contact'])
|
(dispatch [:watch-contact contact'])
|
||||||
(dispatch [:discoveries-send-portions chat-id])))))
|
(dispatch [:discoveries-send-portions chat-id])))))
|
||||||
|
|
Loading…
Reference in New Issue