Converted *Ajax into *Fetch (because we use the Fetch API, not jQuery.ajax)

This commit is contained in:
djmaze 2020-09-14 19:40:56 +02:00
parent bb4d66d6d2
commit 29cf711a6a
52 changed files with 399 additions and 540 deletions

View file

@ -38,8 +38,7 @@ import MessageStore from 'Stores/User/Message';
import * as Local from 'Storage/Client';
import Remote from 'Remote/User/Ajax';
import Promises from 'Promises/User/Ajax';
import Remote from 'Remote/User/Fetch';
import { getApp } from 'Helper/Apps/User';
@ -781,7 +780,7 @@ class MessageViewMailBoxUserView extends AbstractViewNext {
downloadAsZip() {
const hashes = this.getAttachmentsHashes();
if (hashes.length) {
Promises.attachmentsActions('Zip', hashes, this.downloadAsZipLoading)
Remote.attachmentsActions('Zip', hashes, this.downloadAsZipLoading)
.then((result) => {
if (result && result.Result && result.Result.Files && result.Result.Files[0] && result.Result.Files[0].Hash) {
getApp().download(attachmentDownload(result.Result.Files[0].Hash));