]> git.openstreetmap.org Git - rails.git/commitdiff
Fix new rubocop warnings
authorTom Hughes <tom@compton.nu>
Tue, 28 May 2024 16:39:33 +0000 (17:39 +0100)
committerTom Hughes <tom@compton.nu>
Tue, 28 May 2024 16:39:33 +0000 (17:39 +0100)
app/models/trace.rb
config/initializers/abstract_adapter.rb
config/initializers/cors.rb
config/initializers/i18n.rb
config/initializers/mail_delivery_job.rb
config/initializers/oauth.rb
config/initializers/router.rb
config/initializers/rtlcss.rb
lib/osm.rb

index d1f917571a21287f5de4e0a7a290e8e8337babb3..20723b98d01ddc7e0efe3d732879c12c8345d77b 100644 (file)
@@ -81,7 +81,7 @@ class Trace < ApplicationRecord
             :content_type => content_type(attachable.path),
             :identify => false)
     else
-      super(attachable)
+      super
     end
   end
 
index 2bc4f5e59d40d07f552d36417bd3f211eda8d6ee..9d59656c7b2cd4255d019c523bf57952249e0648 100644 (file)
@@ -6,7 +6,7 @@ if defined?(ActiveRecord::ConnectionAdaptors::AbstractAdapter)
           if e.is_a?(Timeout::Error) || e.is_a?(OSM::APITimeoutError)
             e
           else
-            super(e, sql)
+            super
           end
         end
       end
index fdbf11a2ce05cacaaffcdd4a90a822518be92e81..e7b813b73f788fb7bf4cac947007c2ff0154340d 100644 (file)
@@ -6,7 +6,7 @@
 module OpenStreetMap
   class Cors < Rack::Cors
     def call(env)
-      status, headers, body = super(env)
+      status, headers, body = super
       headers["Cache-Control"] = "no-cache" if headers["Access-Control-Allow-Origin"]
       [status, headers, body]
     end
index 266e41cbb98d501435ba985efbdba9af475c8d63..8f74c3cd39455a0b5548aa8d6a364da9259a1309 100644 (file)
@@ -18,7 +18,7 @@ module OpenStreetMap
       def store_translations(locale, data, options = {})
         locale = ::I18n::Locale::Tag::Rfc4646.tag(locale).to_s
 
-        super(locale, data, options)
+        super
       end
     end
 
index 4bab2000b03ed897a600133b22bb9231ca32d4e8..30b23d2ddb47fa298df8dcba50a8aa5a82d3edc6 100644 (file)
@@ -4,7 +4,7 @@ module OpenStreetMap
       def perform(mailer, mail_method, delivery_method, *args, **kwargs)
         kwargs = args.pop if kwargs.empty? && args.last.is_a?(Hash)
 
-        super(mailer, mail_method, delivery_method, *args, **kwargs)
+        super
       end
     end
   end
index fbe4ad219161a6c87d58c872a98aced64b1acdfd..812e6610d9e67a46b1df270cd5a201cf41d3dff4 100644 (file)
@@ -45,7 +45,7 @@ module OpenStreetMap
         status = options.delete(:status) || :ok
         head status, options
       else
-        super(options)
+        super
       end
     end
 
@@ -61,7 +61,7 @@ module OpenStreetMap
           end
         end
 
-        super(controller)
+        super
       end
     end
   end
index 4357a87f25f47ea0cc98c8da6d9f155ed8dad750..849aba2ad15f428785b83f457b0141933dbdfd7a 100644 (file)
@@ -5,7 +5,7 @@ module OpenStreetMap
   module Router
     module ForceEncoding
       def normalize_path(path)
-        super(path).force_encoding("UTF-8")
+        super.force_encoding("UTF-8")
       end
     end
   end
index 11e4e0d5c053894f3752e730c06879d48e667dbb..793c484fc40127058a5ab790dcf0ae337151e6c8 100644 (file)
@@ -2,7 +2,7 @@ require "rtlcss"
 
 class RtlcssSCSSProcessor < SassC::Rails::ScssTemplate
   def self.call(input)
-    output = super(input)
+    output = super
     data = Rtlcss.flip_css(output[:data])
     output.delete(:map)
     output.merge(:data => data)
index 65eab6907a00ff6008299f28d7d2beb8b674d78c..a0fcef8b9f2cf86a238844b0b5170f8dd0552fde 100644 (file)
@@ -8,7 +8,7 @@ module OSM
   # The base class for API Errors.
   class APIError < RuntimeError
     def initialize(message = "Generic API Error")
-      super(message)
+      super
     end
 
     def status