X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/83425edd8da6a01047702cbb3ac8642f3ef452fa..e89a78fff858d5db07f6959a39dd9655dc46008e:/app/controllers/api_controller.rb diff --git a/app/controllers/api_controller.rb b/app/controllers/api_controller.rb index 6ce8a0ef2..17c98fe8b 100644 --- a/app/controllers/api_controller.rb +++ b/app/controllers/api_controller.rb @@ -144,8 +144,8 @@ class ApiController < ApplicationController ## # wrap an api call in a timeout - def api_call_timeout(&block) - Timeout.timeout(Settings.api_timeout, &block) + def api_call_timeout(&) + Timeout.timeout(Settings.api_timeout, &) rescue ActionView::Template::Error => e e = e.cause