I''ve got a table in my DB called addresses. Generated scaffolding code with script/generate scaffold Address AccountAdmin::Address Now when I go to http://localhost:3000/account_admin/address I get a NameError: NameError in Account_admin/address#index uninitialized constant Addres /app/controllers/account_admin/address_controller.rb:8:in `list'' /app/controllers/account_admin/address_controller.rb:3:in `index'' script/server:125 This error occured while loading the following files: addres.rb Huh? Well of course it can''t load addres.rb...it doesn''t exist. But why on earth is it looking for addres.rb instead of address.rb in the first place? I can''t find anywhere it explicitly loads addres.rb...so I''m way confused. Been spending too much time on this, and it doesn''t matter how many times I start fresh and regenerate the scaffolding, it always looks for the wrong name. Any ideas? Pat
This was an inflector issue has been fixed. What version of Rails are you running? http://dev.rubyonrails.com/ticket/1404 Matt On Jul 29, 2005, at 2:44 AM, Pat Maddox wrote:> I''ve got a table in my DB called addresses. Generated scaffolding > code with > script/generate scaffold Address AccountAdmin::Address > > Now when I go to http://localhost:3000/account_admin/address I get > a NameError: > NameError in Account_admin/address#index > > uninitialized constant Addres > > /app/controllers/account_admin/address_controller.rb:8:in `list'' > /app/controllers/account_admin/address_controller.rb:3:in `index'' > script/server:125 > > This error occured while loading the following files: > addres.rb > > > Huh? Well of course it can''t load addres.rb...it doesn''t exist. But > why on earth is it looking for addres.rb instead of address.rb in the > first place? I can''t find anywhere it explicitly loads addres.rb...so > I''m way confused. Been spending too much time on this, and it doesn''t > matter how many times I start fresh and regenerate the scaffolding, it > always looks for the wrong name. Any ideas? > > Pat > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails > >Matt Pelletier pelletierm-A1PILTyJ15gXhy9q4Lf3Ug@public.gmane.org
I''m running 0.13.1...that''s the latest, right? On 7/29/05, Matt Pelletier <pelletierm-A1PILTyJ15gXhy9q4Lf3Ug@public.gmane.org> wrote:> This was an inflector issue has been fixed. What version of Rails are > you running? > > http://dev.rubyonrails.com/ticket/1404 > > Matt > > On Jul 29, 2005, at 2:44 AM, Pat Maddox wrote: > > > I''ve got a table in my DB called addresses. Generated scaffolding > > code with > > script/generate scaffold Address AccountAdmin::Address > > > > Now when I go to http://localhost:3000/account_admin/address I get > > a NameError: > > NameError in Account_admin/address#index > > > > uninitialized constant Addres > > > > /app/controllers/account_admin/address_controller.rb:8:in `list'' > > /app/controllers/account_admin/address_controller.rb:3:in `index'' > > script/server:125 > > > > This error occured while loading the following files: > > addres.rb > > > > > > Huh? Well of course it can''t load addres.rb...it doesn''t exist. But > > why on earth is it looking for addres.rb instead of address.rb in the > > first place? I can''t find anywhere it explicitly loads addres.rb...so > > I''m way confused. Been spending too much time on this, and it doesn''t > > matter how many times I start fresh and regenerate the scaffolding, it > > always looks for the wrong name. Any ideas? > > > > Pat > > _______________________________________________ > > Rails mailing list > > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > > http://lists.rubyonrails.org/mailman/listinfo/rails > > > > > > Matt Pelletier > pelletierm-A1PILTyJ15gXhy9q4Lf3Ug@public.gmane.org > > >