diff options
author | colin <colin@cicadas.surf> | 2023-01-01 08:48:50 -0800 |
---|---|---|
committer | colin <colin@cicadas.surf> | 2023-01-01 08:48:50 -0800 |
commit | 7a3b904c26e2a08a88f58684d03aff3fb2a39c86 (patch) | |
tree | e25e9f241715ec9003f10f8b2e704264e87bbf80 /model.lisp | |
parent | c0ff3d5317e2a70329fde1b56b52dfa203f9c445 (diff) |
Add: password reset feature
Diffstat (limited to 'model.lisp')
-rw-r--r-- | model.lisp | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -99,6 +99,13 @@ (with-transaction () (make-instance 'user :name name))) +(defun set-new-password (user pw) + (with-transaction () + (setf (user-pwhash user) + (hash-string pw (user-pwsalt user))) + t)) + + (defun use-invite-with-code (code username pw) (with-transaction () (when-let (invite (invite-by-code code)) |