Created
October 22, 2015 09:03
-
-
Save SomeoneWeird/eb2d18b851417b1f3c20 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"use strict"; | |
Object.defineProperty(exports, "__esModule", { | |
value: true | |
}); | |
var DELETEKEY = require("../lib/deleteKey"); | |
function anyValidator(args, childValidators, data) { | |
if (data === undefined) { | |
if (args.opt) { | |
return DELETEKEY; | |
} | |
throw new Error("required Any value"); | |
} | |
return data; | |
} | |
exports["default"] = { | |
name: "Any", | |
fn: anyValidator | |
}; | |
module.exports = exports["default"]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"use strict"; | |
const DELETEKEY = require("../lib/deleteKey"); | |
function anyValidator(args, childValidators, data) { | |
if(data === undefined) { | |
if(args.opt) { | |
return DELETEKEY; | |
} | |
throw new Error("required Any value"); | |
} | |
return data; | |
} | |
export default { | |
name: "Any", | |
fn: anyValidator | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment