fix post status for error handling

This commit is contained in:
Henry Jameson 2026-07-08 20:31:17 +03:00
commit 7bc74083d0

View file

@ -596,16 +596,18 @@ const PostStatusForm = {
? this.postHandler
: statusPoster.postStatus
postHandler(postingOptions).then((data) => {
if (!data.error) {
postHandler(postingOptions)
.then((data) => {
this.abandonDraft()
this.clearStatus()
this.$emit('posted', data)
} else {
this.error = data.error
}
this.posting = false
})
})
.catch((error) => {
this.error = error
})
.finally(() => {
this.posting = false
})
},
previewStatus() {
if (this.emptyStatus && this.newStatus.spoilerText.trim() === '') {