ruby on rails - Uninitialized initializer constant -


i created settings.rb file under initializers folder containing values need initialized once application starts. however, on running rails s "uninitialized contant settings(nameerror)

settings.rb

settings.defaults[:single_phase] = 500 settings.defaults[:three_phase]  = 300 

i created migration accompany , view.

where problem?

in config/application_settings.rb

development:   single_phase: 200 

and use anywhere in app

app_settings['single_phase'] 

which returns 200


Comments

Popular posts from this blog

ios - Realm over CoreData should I use NSFetchedResultController or a Dictionary? -

authentication - Mongodb revoke acccess to connect test database -

r - Update two sets of radiobuttons reactively - shiny -