lib/index.js
function createErrorMessage(errorcode) {
	if (errorcode in ERRORS) {
		var args = Array.prototype.slice.call(arguments,1);
		var entry = ERRORS[errorcode];
		if (entry.argcount && entry.argcount!==args.length) {
			// this should only ever get called if we have a bug in this library
			throw new Error("Internal failure. Unexpected usage of internal command. Please report error code: "+errorcode+"(invalid args) to the developer with the following stack trace:"+new Error().stack);
		}
		return new RequestSSLError((args.length ? util.format.apply(util.format,[entry.message].concat(args)) : entry.message), errorcode);
	}
	else {
		// this should only ever get called if we have a bug in this library
		throw new Error("Internal failure. Unexpected usage of internal command. Please report error code: "+errorcode+"(invalid error code) to the developer with the following stack trace:"+new Error().stack);
	}
}
function createErrorMessage(errorcode) {
	if (errorcode in ERRORS) {
		var args = Array.prototype.slice.call(arguments,1);
		var entry = ERRORS[errorcode];
		if (entry.argcount && entry.argcount!==args.length) {
			// this should only ever get called if we have a bug in this library
			throw new Error("Internal failure. Unexpected usage of internal command. Please report error code: "+errorcode+"(invalid args) to the developer with the following stack trace:"+new Error().stack);
		}
		return new RequestSSLError((args.length ? util.format.apply(util.format,[entry.message].concat(args)) : entry.message), errorcode);
	}
	else {
		// this should only ever get called if we have a bug in this library
		throw new Error("Internal failure. Unexpected usage of internal command. Please report error code: "+errorcode+"(invalid error code) to the developer with the following stack trace:"+new Error().stack);
	}
}
function createErrorMessage ( errorcode ) { if ( errorcode in ERRORS ) { var args = Array . prototype . slice . call ( arguments , 1 ) ; var entry = ERRORS [ errorcode ] ; if ( entry . argcount && entry . argcount !== args . length ) { // this should only ever get called if we have a bug in this library throw new Error ( "Internal failure. Unexpected usage of internal command. Please report error code: " + errorcode + "(invalid args) to the developer with the following stack trace:" + new Error ( ) . stack ) ; } return new RequestSSLError ( ( args . length ? util . format . apply ( util . format , [ entry . message ] . concat ( args ) ) : entry . message ) , errorcode ) ; } else { // this should only ever get called if we have a bug in this library throw new Error ( "Internal failure. Unexpected usage of internal command. Please report error code: " + errorcode + "(invalid error code) to the developer with the following stack trace:" + new Error ( ) . stack ) ; } }
construct the proper error message
construct the proper error message