Skip to content

Commit c796187

Browse files
committed
fix: save data copy to memory
1 parent cd648ae commit c796187

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/DataStore.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ export class DataStore<TData = any> {
117117
if(gmFmtVer < this.formatVersion && this.migrations)
118118
parsed = await this.runMigrations(parsed, gmFmtVer);
119119

120-
return { ...(this.cachedData = parsed) };
120+
return this.cachedData = { ...parsed };
121121
}
122122
catch(err) {
123123
console.warn("Error while parsing JSON data, resetting it to the default value.", err);

0 commit comments

Comments
 (0)