]> git.openstreetmap.org Git - rails.git/blobdiff - config/routes.rb
Use shallow routes for diary comments
[rails.git] / config / routes.rb
index 650818d6fc8f45cf0b1839f488ffdbc2cda0f2ba..a5e1240f6c41481f64af00732f24aebb86ce0f6b 100644 (file)
@@ -253,8 +253,8 @@ OpenStreetMap::Application.routes.draw do
   match "/user/:display_name/diary/:id/subscribe" => "diary_entries#subscribe", :via => [:get, :post], :as => :diary_entry_subscribe, :id => /\d+/
   match "/user/:display_name/diary/:id/unsubscribe" => "diary_entries#unsubscribe", :via => [:get, :post], :as => :diary_entry_unsubscribe, :id => /\d+/
   post "/user/:display_name/diary/:id/comments" => "diary_comments#create", :id => /\d+/, :as => :comment_diary_entry
-  post "/user/:display_name/diary/:id/comments/:comment/hide" => "diary_comments#hide", :id => /\d+/, :comment => /\d+/, :as => :hide_diary_comment
-  post "/user/:display_name/diary/:id/comments/:comment/unhide" => "diary_comments#unhide", :id => /\d+/, :comment => /\d+/, :as => :unhide_diary_comment
+  post "/diary_comments/:comment/hide" => "diary_comments#hide", :comment => /\d+/, :as => :hide_diary_comment
+  post "/diary_comments/:comment/unhide" => "diary_comments#unhide", :comment => /\d+/, :as => :unhide_diary_comment
 
   # user pages
   resources :users, :path => "user", :param => :display_name, :only => [:show, :destroy]