mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-10-21 18:48:12 +00:00
(js) Restore immediate deletion of messages
This commit is contained in:
1 parent
67f566ec9d
commit
5c7147cccc
4 files changed
+28
-6
No files matched your search
@@ -676,11 +676,14 @@
|
||||
* @desc Delete multiple messages from mailbox.
|
||||
* @return a promise of the HTTP operation
|
||||
*/
|
||||
Mailbox.prototype.$deleteMessages = function(messages) {
|
||||
var _this = this, uids;
|
||||
Mailbox.prototype.$deleteMessages = function(messages, options) {
|
||||
var _this = this, uids, data;
|
||||
|
||||
uids = _.map(messages, 'uid');
|
||||
return Mailbox.$$resource.post(this.id, 'batchDelete', {uids: uids})
|
||||
data = { uids: uids };
|
||||
if (options) angular.extend(data, options);
|
||||
|
||||
return Mailbox.$$resource.post(this.id, 'batchDelete', data)
|
||||
.then(function(data) {
|
||||
// Update inbox quota
|
||||
if (data.quotas)
|
||||
|
||||
Reference in new issue
Block a user