fix: refs #8113 test e2e & refactor
gitea/salix-front/pipeline/pr-dev This commit looks good Details

This commit is contained in:
Jorge Penadés 2024-11-26 12:04:13 +01:00
parent 9b86f2ddd7
commit 4c2a576915
1 changed files with 2 additions and 2 deletions

View File

@ -284,12 +284,12 @@ export function useArrayData(key = useRoute().meta.moduleName, userOptions) {
}
function processData(data, { map = true, append = true }) {
if (!store.data) {
if (!append) {
store.data = [];
store.map = new Map();
}
if (!Array.isArray(data) || (!map && !append)) store.data = data;
if (!Array.isArray(data)) store.data = data;
else if (!map && append) for (const row of data) store.data.push(row);
else
for (const row of data) {