FakeNitro: Fix trimming wrong content
This commit is contained in:
parent
4f0c0a12dc
commit
612fdf8952
|
@ -585,13 +585,15 @@ export default definePlugin({
|
||||||
for (const [index, child] of children.entries()) children[index] = modifyChild(child);
|
for (const [index, child] of children.entries()) children[index] = modifyChild(child);
|
||||||
|
|
||||||
children = this.clearEmptyArrayItems(children);
|
children = this.clearEmptyArrayItems(children);
|
||||||
this.trimContent(children);
|
|
||||||
|
|
||||||
return children;
|
return children;
|
||||||
};
|
};
|
||||||
|
|
||||||
try {
|
try {
|
||||||
return modifyChildren(lodash.cloneDeep(content));
|
const newContent = modifyChildren(lodash.cloneDeep(content));
|
||||||
|
this.trimContent(newContent);
|
||||||
|
|
||||||
|
return newContent;
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
new Logger("FakeNitro").error(err);
|
new Logger("FakeNitro").error(err);
|
||||||
return content;
|
return content;
|
||||||
|
|
Loading…
Reference in a new issue