diff --git a/src/synapse/dataProvider.js b/src/synapse/dataProvider.js index 50247d8..45ffc3f 100644 --- a/src/synapse/dataProvider.js +++ b/src/synapse/dataProvider.js @@ -204,13 +204,15 @@ const dataProvider = { const res = resourceMap[resource]; const homeserver_url = "https://" + homeserver + res.path; return Promise.all( - params.ids.map(id => jsonClient(`${homeserver_url}/${id}`), { - method: "DELETE", - body: JSON.stringify(params.data, filterNullValues), - }) - ).then(responses => ({ - data: responses.map(({ json }) => json), - })); + params.ids.map(id => + jsonClient(`${homeserver_url}/${id}`, { + method: "DELETE", + body: JSON.stringify(params.data, filterNullValues), + }).then(responses => ({ + data: responses.map(({ json }) => json), + })) + ) + ); }, };