lib/hoptoad_notifier/rack.rb in hoptoad_notifier-2.4.2 vs lib/hoptoad_notifier/rack.rb in hoptoad_notifier-2.4.4
- old
+ new
@@ -24,15 +24,17 @@
def call(env)
begin
response = @app.call(env)
rescue Exception => raised
- HoptoadNotifier.notify_or_ignore(raised, :rack_env => env)
+ error_id = HoptoadNotifier.notify_or_ignore(raised, :rack_env => env)
+ env['hoptoad.error_id'] = error_id
raise
end
if env['rack.exception']
- HoptoadNotifier.notify_or_ignore(env['rack.exception'], :rack_env => env)
+ error_id = HoptoadNotifier.notify_or_ignore(env['rack.exception'], :rack_env => env)
+ env['hoptoad.error_id'] = error_id
end
response
end
end