mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2025-12-16 22:10:13 +01:00
Update all rules to better handle wrongly-typed configuration parameters.
This commit is contained in:
parent
26ad0550ec
commit
3238ed4249
25 changed files with 134 additions and 39 deletions
|
|
@ -14,7 +14,7 @@ module.exports = {
|
|||
"description": "Code block style",
|
||||
"tags": [ "code" ],
|
||||
"function": function MD046(params, onError) {
|
||||
let expectedStyle = params.config.style || "consistent";
|
||||
let expectedStyle = String(params.config.style || "consistent");
|
||||
params.tokens
|
||||
.filter((token) => token.type === "code_block" || token.type === "fence")
|
||||
.forEach((token) => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue