]> git.openstreetmap.org Git - rails.git/blobdiff - app/controllers/application_controller.rb
Localisation updates from https://translatewiki.net.
[rails.git] / app / controllers / application_controller.rb
index fdc2ac4e8694191790ffadab11ae9bbe5e55dc54..fc90e0be7874652475307a695eefb2aece8990fb 100644 (file)
@@ -21,7 +21,7 @@ class ApplicationController < ActionController::Base
 
   def self.allow_thirdparty_images(**options)
     content_security_policy(options) do |policy|
-      policy.img_src("*")
+      policy.img_src("*", :data)
     end
   end
 
@@ -215,10 +215,10 @@ class ApplicationController < ActionController::Base
 
   ##
   # wrap a web page in a timeout
-  def web_timeout(&block)
+  def web_timeout(&)
     raise Timeout::Error if Settings.web_timeout.negative?
 
-    Timeout.timeout(Settings.web_timeout, &block)
+    Timeout.timeout(Settings.web_timeout, &)
   rescue ActionView::Template::Error => e
     e = e.cause