[katello-devel] before_filter behavior and notices

Lukas Zapletal lzap at redhat.com
Wed Jul 20 14:17:29 UTC 2011


On 07/20/2011 04:14 PM, Dmitri Dolguikh wrote:
> You could also add a common exception handler to ApplicationContoller
> using rescue_from.

Yeah, we do the same in the api_controller (which is 
ApplicationController for API controllers):

   rescue_from HttpErrors::NotFound, :with => proc { |e| 
render_exception(404, e) }

LZ

-- 
Later,

  Lukas Zapletal | E32E400A
  RHN Satellite Engineering
  Red Hat Czech s.r.o. Brno




More information about the katello-devel mailing list