Change summary
sgx_jmp.rb | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
Detailed changes
@@ -185,9 +185,10 @@ def poll_for_notify(db)
repo.find(notify[:extra]).then do |customer|
DbNotification.for(notify, customer, repo)
end
- }.then(&:call).then {
- EM.add_timer(0.5) { poll_for_notify(db) }
- }.catch(&method(:panic))
+ }.then(&:call).catch { |e|
+ log.fatal("Error during poll_for_notify", e)
+ Sentry.capture_exception(e)
+ }.then { EM.add_timer(0.5) { poll_for_notify(db) } }
end
def load_plans_to_db!