Skip to content

Commit

Permalink
Merge pull request jacekschae#24 from kimchichef/patch-2
Browse files Browse the repository at this point in the history
Update events.cljs
  • Loading branch information
jacekschae authored Oct 4, 2022
2 parents 1957f2c + 5b7b378 commit ae3c15d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/conduit/events.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@
;; -- POST Login @ /api/users/login -------------------------------------------
;;
(reg-event-fx ;; usage (dispatch [:login user])
:login ;; triggered when a users submits login form
:login ;; triggered when a user submits login form
(fn [{:keys [db]} [_ credentials]] ;; credentials = {:email ... :password ...}
{:db (assoc-in db [:loading :login] true)
:http-xhrio {:method :post
Expand Down Expand Up @@ -416,7 +416,7 @@
;; -- POST Registration @ /api/users ------------------------------------------
;;
(reg-event-fx ;; usage (dispatch [:register-user registration])
:register-user ;; triggered when a users submits registration form
:register-user ;; triggered when a user submits registration form
(fn [{:keys [db]} [_ registration]] ;; registration = {:username ... :email ... :password ...}
{:db (assoc-in db [:loading :register-user] true)
:http-xhrio {:method :post
Expand Down Expand Up @@ -449,7 +449,7 @@
;; -- PUT Update User @ /api/user ---------------------------------------------
;;
(reg-event-fx ;; usage (dispatch [:update-user user])
:update-user ;; triggered when a users updates settgins
:update-user ;; triggered when a user updates settings
(fn [{:keys [db]} [_ user]] ;; user = {:img ... :username ... :bio ... :email ... :password ...}
{:db (assoc-in db [:loading :update-user] true)
:http-xhrio {:method :put
Expand Down

0 comments on commit ae3c15d

Please sign in to comment.