mongoid-app_settings icon indicating copy to clipboard operation
mongoid-app_settings copied to clipboard

Method to persist settings

Open Startouf opened this issue 9 years ago • 0 comments

Suppose I have a Hash setting with nested values. Saving a nested value won't cause settings to be persisted

MySettings.blacklist_by_type # => { abuse: [], hack_attempt: [] }
MySettings.blacklist_by_type[:abuse] = my_blacklist #=> MySettings are not persisted !

I suggest making a persist or save method available as class method MySettings.save

Startouf avatar Jan 11 '17 09:01 Startouf