dist/utils/accepts.js
function accepts(func, validator, message) {
	message = messageBuilder(message || 'vet/utils/accepts error!');

	return function wrapper(){
		var args = arguments;
		if (validator.apply(this, args)) {
			return func.apply(this, args);
		} else {
			throw new Error(message.apply(this, args));
		}
	};
}
function accepts(func, validator, message) {
	message = messageBuilder(message || 'vet/utils/accepts error!');

	return function wrapper(){
		var args = arguments;
		if (validator.apply(this, args)) {
			return func.apply(this, args);
		} else {
			throw new Error(message.apply(this, args));
		}
	};
}
function accepts ( func , validator , message ) { message = messageBuilder ( message || 'vet/utils/accepts error!' ) ; return function wrapper ( ) { var args = arguments ; if ( validator . apply ( this , args ) ) { return func . apply ( this , args ) ; } else { throw new Error ( message . apply ( this , args ) ) ; } } ; }
Wraps a function in a validator which checks its arguments, and throws an error if the arguments are bad.

@param func - the function to wrap
@param validator - the validator function.  This gets passed the arguments as an array
@param message - an optional message string to pass into the error thrown
@returns a wrapped function that throws an error if the arguments do not pass validation
@memberof vet.utils
Wraps a function in a validator which checks its arguments and throws an error if the arguments are bad .