Fix: Empty mailbox
This commit is contained in:
@ -221,7 +221,13 @@
|
|||||||
},
|
},
|
||||||
messages: () => {
|
messages: () => {
|
||||||
const uri = '/mailbox/{{$mailbox_id}}/messages/valid'
|
const uri = '/mailbox/{{$mailbox_id}}/messages/valid'
|
||||||
return Send.get(uri).then(response => {
|
return Send.get(uri).then((response, status, jqXHR) => {
|
||||||
|
if (parseInt(jqXHR.status/100) !== 2) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (jqXHR.status === 204) {
|
||||||
|
this.draw().empty()
|
||||||
|
}
|
||||||
if (this.total === null) {
|
if (this.total === null) {
|
||||||
$(this.id.count).html(' (' + response.total + ')')
|
$(this.id.count).html(' (' + response.total + ')')
|
||||||
this.total = response.total
|
this.total = response.total
|
||||||
@ -448,4 +454,4 @@
|
|||||||
messages.setup()
|
messages.setup()
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
@endpush
|
@endpush
|
||||||
|
Reference in New Issue
Block a user