README.md in rails-settings-cached-2.3.3 vs README.md in rails-settings-cached-2.3.4

- old
+ new

@@ -171,9 +171,29 @@ field :omniauth_google_client_id, default: ENV["OMNIAUTH_GOOGLE_CLIENT_ID"], readonly: true field :omniauth_google_client_secret, default: ENV["OMNIAUTH_GOOGLE_CLIENT_SECRET"], readonly: true end ``` +## Use Setting in Rails initalizing: + +You can't use Setting in these locations: + +``` +config/application.rb +config/environments/*.rb +``` + +If you wants do that, put the setting into `config/initializers/*.rb` + +For example: + +```rb +# config/initializers/devise.rb +Devise.setup do |config| + config.omniauth :twitter, Setting.twitter_api_key, Setting.twitter_api_secret +end +``` + ### Caching flow: ``` Setting.host -> Check Cache -> Exist - Get value of key for cache -> Return |