Skip to content

Commit 5b491c9

Browse files
committed
fix: allow enums to be nonpositive integers
--- type: pre_commit_static_analysis_report description: Results of running static analysis checks when committing changes. report: - task: lint_filenames status: passed - task: lint_editorconfig status: passed - task: lint_markdown status: na - task: lint_package_json status: na - task: lint_repl_help status: na - task: lint_javascript_src status: passed - task: lint_javascript_cli status: na - task: lint_javascript_examples status: na - task: lint_javascript_tests status: na - task: lint_javascript_benchmarks status: na - task: lint_python status: na - task: lint_r status: na - task: lint_c_src status: na - task: lint_c_examples status: na - task: lint_c_benchmarks status: na - task: lint_c_tests_fixtures status: na - task: lint_shell status: na - task: lint_typescript_declarations status: na - task: lint_typescript_tests status: na - task: lint_license_headers status: passed ---
1 parent 654413c commit 5b491c9

File tree

1 file changed

+1
-2
lines changed
  • lib/node_modules/@stdlib/ndarray/base/assert/is-data-type-object/lib

1 file changed

+1
-2
lines changed

lib/node_modules/@stdlib/ndarray/base/assert/is-data-type-object/lib/main.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@
2020

2121
// MODULES //
2222

23-
var isPositiveInteger = require( '@stdlib/assert/is-positive-integer' ).isPrimitive;
2423
var isInteger = require( '@stdlib/assert/is-integer' ).isPrimitive;
2524
var isString = require( '@stdlib/assert/is-string' ).isPrimitive;
2625
var hasProp = require( '@stdlib/assert/has-property' );
@@ -54,7 +53,7 @@ function isDataTypeObject( value ) {
5453
isInteger( value.byteLength ) &&
5554
isString( value.byteOrder ) &&
5655
isString( value.char ) &&
57-
isPositiveInteger( value.enum ) &&
56+
isInteger( value.enum ) &&
5857
hasProp( value, 'value' )
5958
);
6059
}

0 commit comments

Comments
 (0)