mirror of
https://github.com/penpot/penpot.git
synced 2025-05-31 23:01:37 +02:00
✨ Increase default deletion delay.
This commit is contained in:
parent
d6f3efb358
commit
2e438385f3
8 changed files with 29 additions and 25 deletions
|
@ -42,11 +42,12 @@
|
|||
(db/with-atomic [conn pool]
|
||||
(handle-deletion conn props)))
|
||||
|
||||
(defmulti handle-deletion (fn [_ props] (:type props)))
|
||||
(defmulti handle-deletion
|
||||
(fn [_ props] (:type props)))
|
||||
|
||||
(defmethod handle-deletion :default
|
||||
[_conn {:keys [type]}]
|
||||
(log/warn "no handler found for" type))
|
||||
(log/warnf "no handler found for %s" type))
|
||||
|
||||
(defmethod handle-deletion :file
|
||||
[conn {:keys [id] :as props}]
|
||||
|
@ -57,3 +58,8 @@
|
|||
[conn {:keys [id] :as props}]
|
||||
(let [sql "delete from project where id=? and deleted_at is not null"]
|
||||
(db/exec-one! conn [sql id])))
|
||||
|
||||
(defmethod handle-deletion :team
|
||||
[conn {:keys [id] :as props}]
|
||||
(let [sql "delete from team where id=? and deleted_at is not null"]
|
||||
(db/exec-one! conn [sql id])))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue