code: function(handler, priority) {
          if(typeof handler !== 'function') {
            throw new Error('Middleware must be a function.');
          }
  
          if(typeof priority !== 'undefined') handler.priority = priority;
          _layerList.push(handler);
          return _inst;
        }
docs: Internal method to add middleware; called during state transition
  
  @param  {Function} handler  A callback, function(request, next)
  @param  {Number}   priority A number denoting priority
  @return {$state}            Itself; chainable