-
-
Save anonymous/06326dd2adb3048d14e3 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn create-user | |
"Creates a user in the database if valid fields are supplied. | |
Requires name and email" | |
[params] | |
(if (b/valid? params user-validator) | |
(let [{:keys [first-name last-name email password phone]} params] | |
(create-user-in-db! spec first-name last-name email password phone)) | |
(b/validate params user-validator))) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment