Why is my development server not loading? default_controller_and_action': missing :action (ArgumentError)

前端 未结 6 2052
我在风中等你
我在风中等你 2020-12-09 08:17

I\'m a Ruby nuby (and new to Stack Overflow) working on the Rails Tutorial by Michael Hartl and all of a sudden my development server won\'t load and keeps exiting. Console

6条回答
  •  执笔经年
    2020-12-09 09:02

    When I ran into this problem, it was because one of the routes in routes.rb had a slash (/) instead of the hash (#) when using the controller#action syntax (I used "controller/action", which was incorrect).

    For example, I accidentally had root :to => 'home/index'. It was supposed to be root :to => 'home#index'.

    I found this solution in here.

提交回复
热议问题