fix: redirect to home when deleting a page

This commit is contained in:
Tienson Qin
2022-07-04 20:42:41 +08:00
parent e7c64d3dfd
commit 73a202b3c2
2 changed files with 3 additions and 1 deletions

View File

@@ -309,6 +309,7 @@
(defn delete!
[page-name ok-handler & {:keys [delete-file?]
:or {delete-file? true}}]
(route-handler/redirect-to-home!)
(when page-name
(when-let [repo (state/get-current-repo)]
(let [page-name (util/page-name-sanity-lc page-name)