module Roda::RodaPlugins::StatusHandler::InstanceMethods

def _roda_after_20__status_handler(result)

If routing returns a response we have a handler for, call that handler.
def _roda_after_20__status_handler(result)
  if result && (meth, arity = opts[:status_handler][result[0]]; meth) && (v = result[2]).is_a?(Array) && v.empty?
    res = @_response
    res.headers.clear
    res.status = result[0]
    result.replace(_roda_handle_route{arity == 1 ? send(meth, @_request) : send(meth)})
  end
end