Skip to content

Commit

Permalink
refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
OmarBasem committed Dec 8, 2022
1 parent 53880b1 commit 94ed5a4
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/status_im/group_chats/core.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
(fx/defn remove-member
"Format group update message and sign membership"
{:events [:group-chats.ui/remove-member-pressed]}
[_ chat-id member do-not-navigate?]
[{{:keys [current-chat-id selected-participants]} :db :as cofx} chat-id member do-not-navigate?]
{::json-rpc/call [{:method "wakuext_removeMemberFromGroupChat"
:params [nil chat-id member]
:js-response true
Expand Down
12 changes: 6 additions & 6 deletions src/status_im/ui2/screens/chat/group_details/view.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -82,12 +82,12 @@
:search? true}]
[rn/view {:style style/bottom-container}
[quo2/button {:style {:flex 1}
:on-press #(do
(rf/dispatch [:group-chats.ui/add-members-pressed])
(remove-members chat-id)
(reset! removed ())
(reset! added ())
(rf/dispatch [:bottom-sheet/hide]))
:on-press (fn []
(rf/dispatch [:group-chats.ui/add-members-pressed])
(remove-members chat-id)
(reset! removed ())
(reset! added ())
(rf/dispatch [:bottom-sheet/hide]))
:disabled (and (zero? (count @added)) (zero? (count @removed)))}
(i18n/label :t/save)]]]))])))

Expand Down

0 comments on commit 94ed5a4

Please sign in to comment.