Sha256: 0d1233de0476c09a2388f214497530a165eb84ae121ac36791025aa05591b23e
Contents?: true
Size: 478 Bytes
Versions: 4
Compression:
Stored size: 478 Bytes
Contents
# encoding: utf-8 class Exceptions < Rango::Controller attr_reader :handler # handle NotFound exceptions (404) def not_found @handler = :not_found render :format => :html end # handle NotAcceptable exceptions (406) def not_acceptable @handler = :not_acceptable render "Handled by: not_acceptable" end # # Any client error (400 series) def client_error @handler = :client_error render "Handled by: client_error" end end
Version data entries
4 entries across 4 versions & 1 rubygems