huacnlee / rails-settings-cached

Global settings for your Rails application.
Other
1.06k stars 202 forks source link

Change in behavior for integer #237

Closed stevenou closed 1 year ago

stevenou commented 1 year ago

In versions prior to 2.9.0, one could set an integer setting to nil (or not set it at all). Now, due to deserialize method that forces to_i, a nil value deserializes to 0 instead of nil.

Therefore, it breaks any code checking for nil setting. I believe nil should be a legitimate value that should be allowed for an integer setting.

huacnlee commented 1 year ago

Just released v2.9.2 to fix this issue.