Merge pull request #4050 from penpot/niwinz-staging-bugfix-8

🐛 Fix incorrect props handling on profile registration
This commit is contained in:
Alejandro 2024-01-25 16:14:19 +01:00 committed by GitHub
commit d5aa4f3ee4
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 21 additions and 33 deletions

View file

@ -333,7 +333,9 @@
(defn register-profile
[{:keys [::db/conn] :as cfg} {:keys [token fullname] :as params}]
(let [claims (tokens/verify (::main/props cfg) {:token token :iss :prepared-register})
params (assoc claims :fullname fullname)
params (-> claims
(into params)
(assoc :fullname fullname))
is-active (or (:is-active params)
(not (contains? cf/flags :email-verification)))