We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 240cf04 commit 38783bcCopy full SHA for 38783bc
lib/rules/array.js
@@ -10,7 +10,7 @@ module.exports = function ({ schema, messages }, path, context) {
10
sanitized = true;
11
// Convert to array if not and the value is not null or undefined
12
src.push(`
13
- if (!Array.isArray(value) && [null, undefined].indexOf(value) === -1) {
+ if (!Array.isArray(value) && value != null) {
14
value = [value];
15
}
16
`);
0 commit comments