Find controller in Request

Hello all,

I have a get request, say SuperDuper.com, which
lists all footballs belonging to the company superduper. However, in
the application controller, I want to create a filter which checks to
see if there are any footballs in the database first and if not,
forwards to a different URL.

Something like

if(request.url.controller == ‘football’)
redirect_to ‘some URL’

I have been looking around for this and cant find it.

Cheers,
John

I have been looking around for this and cant find it.

params[:controller] should be one way to access that datum.

  • donald