]> git.openstreetmap.org Git - rails.git/blobdiff - db/migrate/031_create_countries.rb
Add "text" to the valid formats
[rails.git] / db / migrate / 031_create_countries.rb
index 24331d6a833292cc4cc7bc28a7da5ec5ee5599c9..cc0627cd291fdc1b064811748b854015aa755653 100644 (file)
@@ -24,9 +24,11 @@ class CreateCountries < ActiveRecord::Migration
         maxlon = ele.get_text("bBoxEast").to_s
         maxlat = ele.get_text("bBoxNorth").to_s
 
-        Country.create(:code => code,
-                       :min_lat => minlat.to_f, :max_lat => maxlat.to_f,
-                       :min_lon => minlon.to_f, :max_lon => maxlon.to_f)
+        Country.create({
+          :code => code,
+          :min_lat => minlat.to_f, :max_lat => maxlat.to_f,
+          :min_lon => minlon.to_f, :max_lon => maxlon.to_f
+        }, :without_protection => true)
       end
     end
   end