Skip to content

Commit 7ff8439

Browse files
committed
Activate eslint restrict-template-expressions
Enable the eslint rule restrict-template-expressions
1 parent 6b78ace commit 7ff8439

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

eslint.config.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ export default [
1717
"@typescript-eslint/no-unsafe-call": "off",
1818
"@typescript-eslint/no-unsafe-member-access": "off",
1919
"@typescript-eslint/no-unsafe-return": "off",
20-
"@typescript-eslint/restrict-template-expressions": "off",
2120
},
2221
},
2322
];

src/config.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,7 @@ const loadContextSettings = async () => {
229229
return parse(await response.text());
230230
} catch (e) {
231231
console.error(`Could not parse "${settingsPath}" as TOML: `, e);
232-
throw new SyntaxError(`Could not parse "${settingsPath}" as TOML: ${e}`);
232+
throw new SyntaxError(`Could not parse "${settingsPath}" as TOML: ${String(e)}`);
233233
}
234234

235235
};
@@ -269,7 +269,7 @@ const validate = (obj: Record<string, any> | null, allowParse: boolean, src: str
269269
} catch (e) {
270270
console.warn(
271271
`Validation of setting "${path}" (${sourceDescription}) with value "${JSON.stringify(value)}" failed: `
272-
+ `${e}. Ignoring.`,
272+
+ `${String(e)}. Ignoring.`,
273273
);
274274
return null;
275275
}

0 commit comments

Comments
 (0)