Skip to content

Commit

Permalink
Rewrite RSS route. [#24]
Browse files Browse the repository at this point in the history
  • Loading branch information
marnen committed May 28, 2009
1 parent ce621bf commit 359d777
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions app/controllers/events_controller.rb
Expand Up @@ -59,6 +59,7 @@ class EventsController < ApplicationController

# Generate an RSS feed of events.
def feed
params[:format] = params[:fmt]
respond_to do |format|
format.rss do
@key = params[:key]
Expand Down
4 changes: 2 additions & 2 deletions config/routes.rb
Expand Up @@ -42,8 +42,8 @@
map.root :controller => 'events'

map.connect 'events/index', :controller => 'events', :action => 'index'

map.formatted_feed_events 'events/feed.:format/:key', :controller => 'events', :action => 'feed'
map.feed_events 'events/feed.:fmt/:key', :controller => 'events', :action => 'feed' # can't use :format with this URL syntax
map.resources :events

map.resources :permissions, :member => {:destroy => :get}
Expand Down

0 comments on commit 359d777

Please sign in to comment.