]> git.openstreetmap.org Git - rails.git/blobdiff - config/routes.rb
Make api create way path resourceful
[rails.git] / config / routes.rb
index 75e05d2cad12bbbd58f6c23be8895826abd16ff3..b420dcedb947deb6f758c87a8c003ecfe3ff1431 100644 (file)
@@ -39,7 +39,6 @@ OpenStreetMap::Application.routes.draw do
     put "node/:id" => "nodes#update", :id => /\d+/
     delete "node/:id" => "nodes#delete", :id => /\d+/
 
-    put "way/create" => "ways#create"
     get "way/:id/history" => "old_ways#history", :as => :api_way_history, :id => /\d+/
     get "way/:id/full" => "ways#full", :as => :way_full, :id => /\d+/
     get "way/:id/relations" => "relations#relations_for_way", :as => :way_relations, :id => /\d+/
@@ -64,7 +63,8 @@ OpenStreetMap::Application.routes.draw do
     resources :nodes, :only => [:index, :create]
     put "node/create" => "nodes#create", :as => nil
 
-    resources :ways, :only => :index
+    resources :ways, :only => [:index, :create]
+    put "way/create" => "ways#create", :as => nil
 
     resources :relations, :only => :index