简体   繁体   中英

Updating rails to 3.1.1 i get uninitialized constant Product::RAILS_ROOT

After updating from 3.0.1 to 3.1.1 my application according the relevant railscast i seem to get this:

uninitialized constant Product::RAILS_ROOT

Product is my main object

Try this instead:

Rails.root

add to_s if you need it as a string!

RAILS_ROOT no longer exists. Use Rails.root instead.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM