🐛 Fix incorrect team features handling on onboarding team creation

This commit is contained in:
Andrey Antukh 2024-04-10 15:26:33 +02:00
parent 389c394f39
commit 347276fb4e
3 changed files with 13 additions and 8 deletions

View file

@ -869,7 +869,12 @@
::sm/params schema:create-team-with-invitations}
[{:keys [::db/pool] :as cfg} {:keys [::rpc/profile-id emails role] :as params}]
(db/with-atomic [conn pool]
(let [params (assoc params :profile-id profile-id)
(let [features (-> (cfeat/get-enabled-features cf/flags)
(cfeat/check-client-features! (:features params)))
params (assoc params
:profile-id profile-id
:features features)
cfg (assoc cfg ::db/conn conn)
team (create-team cfg params)
profile (db/get-by-id conn :profile profile-id)