Skip to content

Commit 7c7d074

Browse files
authored
Merge pull request #3 from wuespace/fix-read-only
Fix --read-only mode
2 parents 0e9736b + d1a90eb commit 7c7d074

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

lib/extract/JsonWriter.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,12 +42,11 @@ export class JsonWriter<T extends string> {
4242
}
4343

4444
public writeAll(): void {
45-
if (this.isReadOnly) {
46-
return;
47-
}
48-
4945
for (const lang of Object.keys(this.config.languages) as T[]) {
5046
const processed = this.processLang(lang);
47+
if (this.isReadOnly) {
48+
continue;
49+
}
5150
const path = normalizePath(this.config.languages[lang]);
5251
const content = JSON.stringify(processed, null, 2) + "\n";
5352
Deno.writeTextFileSync(path, content);

0 commit comments

Comments
 (0)