Class: Katgut::RulesController

Inherits:
ApplicationController show all
Defined in:
app/controllers/katgut/rules_controller.rb

Instance Method Summary collapse

Instance Method Details

#showObject



3
4
5
6
7
8
9
10
# File 'app/controllers/katgut/rules_controller.rb', line 3

def show
  @rule = Rule.active.find_by!(source: params[:id])
  redirect_to @rule.regular_destination
rescue => e
  redirect_to Katgut.config.fall_back_path
ensure
  after_redirection_callback
end