Skip to content

Commit

Permalink
chore: New-parens rule schema improvement (#16879)
Browse files Browse the repository at this point in the history
  • Loading branch information
mho22 authored and MHO committed Apr 5, 2023
1 parent a3aa6f5 commit 9e39212
Showing 1 changed file with 5 additions and 14 deletions.
19 changes: 5 additions & 14 deletions lib/rules/new-parens.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,20 +31,11 @@ module.exports = {
},

fixable: "code",
schema: {
anyOf: [
{
type: "array",
items: [
{
enum: ["always", "never"]
}
],
minItems: 0,
maxItems: 1
}
]
},
schema: [
{
enum: ["always", "never"]
}
],
messages: {
missing: "Missing '()' invoking a constructor.",
unnecessary: "Unnecessary '()' invoking a constructor with no arguments."
Expand Down

0 comments on commit 9e39212

Please sign in to comment.