Sha256: 1f70f8ff7ecc6563cbf2c499553d789dc7f44000e4d3c182d3805e0ee1333a3c
Contents?: true
Size: 431 Bytes
Versions: 13
Compression:
Stored size: 431 Bytes
Contents
# frozen_string_literal: true prepend Actions class TharSheBlows < StandardError end on 'blow' do raise TharSheBlows.new("Arrrh!") end # The ExceptionHandler middleware will redirect here when an exception occurs. If this also fails, things get ugly. on 'exception' do |request| if request.params['fatal'] raise TharSheBlows.new("Yarrh!") else succeed! :content => 'Error Will Robertson', :type => 'text/plain' end end
Version data entries
13 entries across 13 versions & 1 rubygems