We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2799e88 commit b463490Copy full SHA for b463490
src/main.ts
@@ -42,6 +42,8 @@ export default class ChemPlugin extends Plugin {
42
const candidate = Object.assign({}, await this.loadData());
43
if ('version' in candidate && candidate.version == SETTINGS_VERSION)
44
this.settings = Object.assign({}, DEFAULT_SETTINGS, candidate);
45
+ else if (Object.keys(candidate).length === 0)
46
+ this.settings = Object.assign({}, DEFAULT_SETTINGS);
47
else
48
this.settings = Object.assign(
49
{},
0 commit comments