X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/83425edd8da6a01047702cbb3ac8642f3ef452fa..9b533b2789df4876a789f54e992e4e9b00ece56d:/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