code: function createError(name, message) {
          var e = new Error(message);
          e.name = name || 'DOMException';
          e.message = message;
          return e;
      }
docs: Creates a generic Error object
  @returns {Error}