]> git.openstreetmap.org Git - rails.git/commitdiff
Fix new rubocop warnings
authorTom Hughes <tom@compton.nu>
Tue, 2 Mar 2021 08:24:15 +0000 (08:24 +0000)
committerTom Hughes <tom@compton.nu>
Tue, 2 Mar 2021 08:24:15 +0000 (08:24 +0000)
app/controllers/api/changesets_controller.rb
lib/bounding_box.rb

index 29a57570d154383dbbbf3381be8ba6a86508ea54..34627a1187acca98b026da44c4c3ce5ecc0e0428 100644 (file)
@@ -308,7 +308,7 @@ module Api
         # low, second is high - same as with bounding boxes.
 
         # check that we actually have 2 elements in the array
-        times = time.split(/,/)
+        times = time.split(",")
         raise OSM::APIBadUserInput, "bad time range" if times.size != 2
 
         from, to = times.collect { |t| Time.parse(t) }
index 44375ae5beb85aca7b5ece0ad2f20423975194fd..3b366dc1ef5da4d8b7ea0be87f87da37141ada7b 100644 (file)
@@ -14,7 +14,7 @@ class BoundingBox
   end
 
   def self.from_s(s)
-    BoundingBox.new(*s.split(/,/)) if s.count(",") == 3
+    BoundingBox.new(*s.split(",")) if s.count(",") == 3
   end
 
   def self.from_bbox_params(params)