Closed Maks3w closed 9 years ago
Most basic test does not work due https://github.com/zendframework/zf2/pull/5271/ getRawValues()
returns a list of pairs Input => null
which make this logic to fail.
I think this explains and fixes https://github.com/zendframework/zf2/issues/6638
It's not related. This does not change the meaning of any empty value. This only treat the case when the value is not set (not exists !== empty).
There was impossible to check if value exists or not, so I used notEmpty validator to cover this, but that was not ideal because there was some values treated as empty anyway. This fixes my issue because now I can check not set, is set or not empty, before this PR that was impossible. As I understand this PR adds this functionality.
I'm concerned that this changes test assumptions, as that generally indicates a BC break. Looking at the logic, however, it appears sound. I'll review more fully early next week.
Note: It's impossible to undo all BC Breaks introduced in ZF 2.4. The split of null
between not set and valid value can't be undo.
Prevent the assumption of
null
value to be a synonym of value not set. Null values are valid input values (like JSON object with null values)