function validate( opts, options ) {
	if ( !isObject( options ) ) {
		return new TypeError( format( 'invalid argument. Options argument must be an object. Value: `%s`.', options ) );
	}
	if ( hasOwnProp( options, 'url' ) ) {
		opts.url = options.url;
		if ( !isString( opts.url ) ) {
			return new TypeError( format( 'invalid option. `%s` option must be a string. Option: `%s`.', 'url', opts.url ) );
		}
	}
	if ( hasOwnProp( options, 'message' ) ) {
		opts.message = options.message;
		if ( !isString( opts.message ) ) {
			return new TypeError( format( 'invalid option. `%s` option must be a string. Option: `%s`.', 'message', opts.message ) );
		}
	}
	return null;
}
Validates function options.

@private
@param {Object} opts - destination object
@param {Options} options - options to validate
@param {string} [options.url] - website URL for full error message
@param {string} [options.message] - error message template with `{{url}}` and `{{code}}` placeholders that will be replaced
@returns {(Error|null)} error object or null