diff --git a/app/src/helpers/yunohostArguments.js b/app/src/helpers/yunohostArguments.js
index 75b0fac6..06eb385e 100644
--- a/app/src/helpers/yunohostArguments.js
+++ b/app/src/helpers/yunohostArguments.js
@@ -343,9 +343,9 @@ export function formatFormDataValue (value) {
* @param {Boolean} [extraParams.removeEmpty=true] - Removes "empty" values from the object.
* @return {Object} the parsed data to be sent to the server, with extracted values if specified.
*/
-export function formatFormData (
+export async function formatFormData (
formData,
- { extract = null, flatten = false, removeEmpty = true, removeNull = false, promise = false, multipart = true } = {}
+ { extract = null, flatten = false, removeEmpty = true, removeNull = false, multipart = true } = {}
) {
const output = {
data: {},
@@ -376,14 +376,7 @@ export function formatFormData (
output[type][key] = value
}
}
+ if (promises.length) await Promise.all(promises)
const { data, extracted } = output
- if (promises.length > 0 || promise) {
- return new Promise((resolve, reject) => {
- Promise.all(promises).then((value) => {
- resolve(data)
- })
- })
- } else {
- return extract ? { data, ...extracted } : data
- }
+ return extract ? { data, ...extracted } : data
}
diff --git a/app/src/views/app/AppConfigPanel.vue b/app/src/views/app/AppConfigPanel.vue
index 753ad635..4df0021e 100644
--- a/app/src/views/app/AppConfigPanel.vue
+++ b/app/src/views/app/AppConfigPanel.vue
@@ -155,7 +155,7 @@ export default {
},
applyConfig (id_) {
- formatFormData(this.forms[id_], { promise: true, removeEmpty: false, removeNull: true, multipart: false }).then((formatedData) => {
+ formatFormData(this.forms[id_], { removeEmpty: false, removeNull: true, multipart: false }).then((formatedData) => {
const args = objectToParams(formatedData)
api.put(
diff --git a/app/src/views/app/AppInstall.vue b/app/src/views/app/AppInstall.vue
index 041524c7..1bc08e5d 100644
--- a/app/src/views/app/AppInstall.vue
+++ b/app/src/views/app/AppInstall.vue
@@ -23,10 +23,13 @@
:validation="$v" :server-error="serverError"
@submit.prevent="performInstall"
>
-
+
+
+
@@ -44,9 +47,10 @@