mirror of
https://github.com/elk-zone/elk.git
synced 2024-11-04 16:09:59 +00:00
fix: update route name when delete status (#151)
This commit is contained in:
parent
77a87af46a
commit
2bf4f8913a
1 changed files with 7 additions and 1 deletions
|
@ -79,9 +79,15 @@ const copyLink = async () => {
|
|||
}
|
||||
const deleteStatus = async () => {
|
||||
// TODO confirm to delete
|
||||
if (process.dev) {
|
||||
const result = confirm('[DEV] Are you sure you want to delete this post?')
|
||||
if (!result)
|
||||
return
|
||||
}
|
||||
|
||||
await useMasto().statuses.remove(status.id)
|
||||
if (route.name === '@user-post')
|
||||
|
||||
if (route.name === '@account-status')
|
||||
router.back()
|
||||
|
||||
// TODO when timeline, remove this item
|
||||
|
|
Loading…
Reference in a new issue