Actions
Bug #34141
closedThe validate_presence and validate_readable with predicate broken
Description
When using the following code in modern Ruby, it starts to fail:
validate_presence :setting, if: ->(settings) { false }
This causes the if: part to be interpreted as a setting to validate, rather than as a predicate for :setting.
I reproduced this on Smart Proxy 3.2.0-develop with Ruby 3. It looks like there's no test coverage for this use case.
Actions