remove unneeded .trim from react-virt patch (#4379)

Followup to #4370, per https://github.com/zotero/zotero/pull/4370#discussion_r1674336402
This commit is contained in:
abaevbog 2024-07-11 21:21:45 -07:00 committed by GitHub
parent c3e927e52f
commit f387c67fbc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -54,7 +54,7 @@ async function babelWorker(ev) {
throw new Error(`"_this.state.isScrolling || isScrollingChange(!0), _this.setState({" not found in react-virtualized`);
}
transformed = transformed.replace(onScrollSetStateChunkRegex, (_, p1, p2) => {
return `${p1}ReactDOM.flushSync(() => ${p2.trim()})`;
return `${p1}ReactDOM.flushSync(() => ${p2})`;
});
}
// Patch single-file