Skip to content

Instantly share code, notes, and snippets.

@joshuamiller
Created April 29, 2013 17:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save joshuamiller/5483229 to your computer and use it in GitHub Desktop.
Save joshuamiller/5483229 to your computer and use it in GitHub Desktop.
# config/routes.rb
get '/sign_in' => 'user_sessions#new', :as => :sign_in
post '/sign_in' => 'user_sessions#create', :as => :sign_in
# Output
#=> Invalid route name, already in use: 'sign_in'
#=> You may have defined two routes with the same name using the `:as` option, or you may be overriding a route already defined by a resource with the same naming. For the latter, you can restrict the routes created with `resources` as explained here:
#=> http://guides.rubyonrails.org/routing.html#restricting-the-routes-created
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment