You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
11 lines
293 B
JavaScript
11 lines
293 B
JavaScript
2 years ago
|
"use strict";
|
||
|
|
||
|
const isNegativeStringNumber = require("./string-number/is-negative");
|
||
|
const isNegativeNumber = require("./number/is-negative");
|
||
|
|
||
|
module.exports = function isNegative(value) {
|
||
|
return (typeof value === "string")
|
||
|
? isNegativeStringNumber(value)
|
||
|
: isNegativeNumber(value);
|
||
|
};
|