code: function onError(callback) {
    var code = (arguments.length > 1) ? arguments[1] : 0;
    fire('open.error', code);
    if (typeof callback === 'function') {
      callback(code);
    }
    return code;
  }
docs: onError
  
  @param {Function} callback Callback
  @returns {Number} Error Code