mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-10-18 19:45:58 +08:00
spreading default config instead of referencing
This commit is contained in:
parent
31ac2a4b40
commit
db46b5e380
2 changed files with 7 additions and 3 deletions
|
@ -1821,8 +1821,10 @@ export function apply(
|
|||
}
|
||||
|
||||
export function reset(): void {
|
||||
config = DefaultConfig;
|
||||
apply(DefaultConfig);
|
||||
config = {
|
||||
...DefaultConfig,
|
||||
};
|
||||
apply(config);
|
||||
saveFullConfigToLocalStorage();
|
||||
}
|
||||
|
||||
|
|
|
@ -95,7 +95,9 @@ export async function initSnapshot(): Promise<
|
|||
// }
|
||||
// LoadingPage.updateText("Downloading config...");
|
||||
if (configData) {
|
||||
const newConfig = DefaultConfig;
|
||||
const newConfig = {
|
||||
...DefaultConfig,
|
||||
};
|
||||
|
||||
for (const key in configData.config) {
|
||||
const value = configData.config[key];
|
||||
|
|
Loading…
Add table
Reference in a new issue