Action Dispatch Callbacks
Provides callbacks to be executed before and after dispatching the request.
Methods
- A
-
- B
-
- C
-
- N
-
Included Modules
Class Public methods
after(*args, &block)
Link
Source:
show
|
on GitHub
def after(*args, &block)
set_callback(:call, :after, *args, &block)
end
before(*args, &block)
Link
Source:
show
|
on GitHub
def before(*args, &block)
set_callback(:call, :before, *args, &block)
end
Instance Public methods
call(env)
Link
Source:
show
|
on GitHub
def call(env)
error = nil
result = run_callbacks :call do
@app.call(env)
rescue => error
end
raise error if error
result
end