diff --git a/server/utils/index.js b/server/utils/index.js index ad31560..0dac031 100644 --- a/server/utils/index.js +++ b/server/utils/index.js @@ -2,10 +2,10 @@ const COMBINED_UID_JOINSTR = ', '; -const escapeUid = (uid) => uid.replace(/\,/g,'').replace(COMBINED_UID_JOINSTR, ''); +const escapeUid = (uid) => uid.replace(/,/g, '').replace(COMBINED_UID_JOINSTR, ''); const getCombinedUid = (uidKeys, params) => uidKeys.map((uidKey) => params[uidKey]).join(COMBINED_UID_JOINSTR); -const getCombinedUidWhereFilter = (uidKeys, params) => uidKeys.reduce(((akku, uidKey) => ({ ...akku, [uidKey]: params[uidKey] })),{}); -const getUidParamsFromName = (uidKeys, configName) => configName.split(COMBINED_UID_JOINSTR).reduce((akku, param, i) => ({...akku, [uidKeys[i]]: param}), {}); +const getCombinedUidWhereFilter = (uidKeys, params) => uidKeys.reduce(((akku, uidKey) => ({ ...akku, [uidKey]: params[uidKey] })), {}); +const getUidParamsFromName = (uidKeys, configName) => configName.split(COMBINED_UID_JOINSTR).reduce((akku, param, i) => ({ ...akku, [uidKeys[i]]: param }), {}); const getCoreStore = () => { return strapi.store({ type: 'plugin', name: 'config-sync' });