mirror of
https://github.com/penpot/penpot.git
synced 2025-06-08 01:01:37 +02:00
🐛 Fix incorrect feature handling on absorb-library! fn
Used in shared flag assignation and library deletion
This commit is contained in:
parent
0a77bae8a7
commit
76a6f077a6
12 changed files with 194 additions and 116 deletions
|
@ -149,11 +149,17 @@
|
|||
(sv/defmethod ::get-team
|
||||
{::doc/added "1.17"
|
||||
::sm/params schema:get-team}
|
||||
[cfg {:keys [::rpc/profile-id id file-id]}]
|
||||
(db/tx-run! cfg #(get-team % :profile-id profile-id :team-id id :file-id file-id)))
|
||||
[{:keys [::db/pool]} {:keys [::rpc/profile-id id file-id]}]
|
||||
(get-team pool :profile-id profile-id :team-id id :file-id file-id))
|
||||
|
||||
(defn get-team
|
||||
[conn & {:keys [profile-id team-id project-id file-id] :as params}]
|
||||
|
||||
(dm/assert!
|
||||
"connection or pool is mandatory"
|
||||
(or (db/connection? conn)
|
||||
(db/pool? conn)))
|
||||
|
||||
(dm/assert!
|
||||
"profile-id is mandatory"
|
||||
(uuid? profile-id))
|
||||
|
@ -655,7 +661,7 @@
|
|||
|
||||
(defn update-team-photo
|
||||
[{:keys [::db/pool ::sto/storage] :as cfg} {:keys [profile-id team-id] :as params}]
|
||||
(let [team (get-team cfg :profile-id profile-id :team-id team-id)
|
||||
(let [team (get-team pool :profile-id profile-id :team-id team-id)
|
||||
photo (profile/upload-photo cfg params)]
|
||||
|
||||
(db/with-atomic [conn pool]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue