From 0413c070f7d1ae58cc99bd19a0b5512be849ba20 Mon Sep 17 00:00:00 2001 From: ljf Date: Sat, 8 May 2021 22:49:08 +0200 Subject: [PATCH] [fix] Cherry pick conflict merge error --- app/src/api/api.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/app/src/api/api.js b/app/src/api/api.js index f95e54d0..86507812 100644 --- a/app/src/api/api.js +++ b/app/src/api/api.js @@ -99,6 +99,11 @@ export default { options = { ...options, method, body: objectToParams(data, { addLocale: true }, true) } } + const response = await fetch('/yunohost/api/' + uri, options) + const responseData = await getResponseData(response) + store.dispatch('END_REQUEST', { request, success: response.ok, wait }) + + return response.ok ? responseData : handleError(request, response, responseData) },