Help, I changed a folder name in my app>controller from admin to company and now I get a company is not a class error. I do not have any custom routes set and have changed all references to admin, no joy. Does ruby / rails have a cache of the names? -- Posted via http://www.ruby-forum.com/.
James Whittaker wrote:> Help, > > I changed a folder name in my app>controller from admin to company and > now I get a company is not a class error. > > I do not have any custom routes set and have changed all references to > admin, no joy. > > Does ruby / rails have a cache of the names?Kinda. First things first: have you restarted the web server? -- Alex
James Whittaker
2006-Mar-27 09:34 UTC
[Rails] Re: rename app>controller subfolder crashes app
Alex Young wrote:> James Whittaker wrote: >> Help, >> >> I changed a folder name in my app>controller from admin to company and >> now I get a company is not a class error. >> >> I do not have any custom routes set and have changed all references to >> admin, no joy. >> >> Does ruby / rails have a cache of the names? > Kinda. > > First things first: have you restarted the web server?Yes restarted, i''m running webrick on windows in dev mode. -- Posted via http://www.ruby-forum.com/.
James Whittaker wrote:> Alex Young wrote: >> James Whittaker wrote: >>> Help, >>> >>> I changed a folder name in my app>controller from admin to company and >>> now I get a company is not a class error. >>> >>> I do not have any custom routes set and have changed all references to >>> admin, no joy. >>> >>> Does ruby / rails have a cache of the names? >> Kinda. >> >> First things first: have you restarted the web server? > > Yes restarted, i''m running webrick on windows in dev mode.Where''s the error being thrown from? What''s the full error? -- Alex
James Whittaker
2006-Mar-27 09:42 UTC
[Rails] Re: Re: rename app>controller subfolder crashes app
Alex Young wrote:> James Whittaker wrote: >>>> Does ruby / rails have a cache of the names? >>> Kinda. >>> >>> First things first: have you restarted the web server? >> >> Yes restarted, i''m running webrick on windows in dev mode. > Where''s the error being thrown from? What''s the full error?The error on the page is: TypeError in <controller not set>#<action not set> Company is not a class RAILS_ROOT: ./script/../config/.. When I look at the full trace I get: This error occured while loading the following files: ./script/../config/../app/controllers/company/accounts_controller.rb ./script/../config/../app/controllers/company/base_controller.rb login_system_employee.rb employee.rb company.rb -- Posted via http://www.ruby-forum.com/.
Alex Young
2006-Mar-27 09:48 UTC
[Rails] Re: Re: rename app>controller subfolder crashes app
James Whittaker wrote:> This error occured while loading the following files: > ./script/../config/../app/controllers/company/accounts_controller.rbI don''t suppose there were any line numbers mentioned? What does accounts_controller.rb look like? What URL are you trying to access that triggers this? -- Alex
James Whittaker
2006-Mar-27 09:57 UTC
[Rails] Re: Re: Re: rename app>controller subfolder crashes app
Alex Young wrote:> James Whittaker wrote: >> This error occured while loading the following files: >> ./script/../config/../app/controllers/company/accounts_controller.rb > > I don''t suppose there were any line numbers mentioned? What does > accounts_controller.rb look like? > > What URL are you trying to access that triggers this?No line numbers are mentioned. I have run powerGrep to find all instances of Admin in the entire project and replaced them with Company. Still no joy. I think that once you create a controller sub folder you are stuck with that, it cannot be changed. the URL i''m trying is: http://localhost:3000/company/accounts/login Al the views have been changed & tests still not working. -- Posted via http://www.ruby-forum.com/.
Alex Young
2006-Mar-27 10:07 UTC
[Rails] Re: Re: Re: rename app>controller subfolder crashes app
James Whittaker wrote:> the URL i''m trying is: http://localhost:3000/company/accounts/login > Al the views have been changed & tests still not working.Just a hunch: try http://localhost:3000/company/accounts/login/ and see if that works. -- Alex
James Whittaker
2006-Mar-27 10:17 UTC
[Rails] Re: Re: Re: Re: rename app>controller subfolder crashes app
Alex Young wrote:> James Whittaker wrote: >> the URL i''m trying is: http://localhost:3000/company/accounts/login >> Al the views have been changed & tests still not working. > Just a hunch: try http://localhost:3000/company/accounts/login/ and see > if that works.No joy there. Thanks for your help. I think this is one for the lessons learnt folder. Result: still not resolved. -- Posted via http://www.ruby-forum.com/.
Mats Lindblad
2006-Mar-27 10:33 UTC
[Rails] Re: Re: Re: Re: rename app>controller subfolder crashes app
Skipped content of type multipart/mixed-------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 250 bytes Desc: OpenPGP digital signature Url : http://wrath.rubyonrails.org/pipermail/rails/attachments/20060327/6d8ffb59/signature-0001.bin