forked from validatem/core
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.
15 lines
362 B
JavaScript
15 lines
362 B
JavaScript
"use strict";
|
|
|
|
const assureArray = require("assure-array");
|
|
const isPlainObject = require("@validatem/is-plain-object");
|
|
|
|
const validateArguments = require("./validate-arguments");
|
|
|
|
module.exports = function (args, optionsRules) {
|
|
let result = validateArguments(args, [
|
|
["options", isPlainObject].concat(assureArray(optionsRules))
|
|
]);
|
|
|
|
return result[0];
|
|
};
|