toArray = function (input) {
    if (!input)
      return [];
    else if (_.isArray(input))
      return input;
    else
      return [input];
  }
Add a hook to all routes. The hooks will apply to all routes,
unless you name routes to include or exclude via `only` and `except` options

@param {String} [type] one of 'load', 'unload', 'before' or 'after'
@param {Object} [options] Options to controll the hooks [optional]
@param {Function} [hook] Callback to run
@return {IronRouter}
@api public