function createError(name, message) {
    var e = new Error(message); // DOMException uses the same `toString` as `Error`, so no need to add
    e.name = name || 'DOMException';
    e.message = message;
    return e;
}
/**
 * Creates a generic Error object
 * @returns {Error}
 */
Creates a generic Error object
@returns {Error}
Creates a generic Error object @returns { Error }
function createError(name, message) {
    var e = new Error(message); 
    e.name = name || 'DOMException';
    e.message = message;
    return e;
}
function createError ( name , message ) { var e = new Error ( message ) ; e . name = name || 'DOMException' ; e . message = message ; return e ; }
Creates a generic Error object
 @returns {Error}
Creates a generic Error object @returns { Error }
// DOMException uses the same `toString` as `Error`, so no need to add