Skip to content

fix: treat any falsy row as no record in NoRecordExists - #11

Merged
tyrsson merged 1 commit into
0.1.xfrom
fix/falsy-no-row
Oct 3, 2026
Merged

tyrsson merged 1 commit into
0.1.xfrom
fix/falsy-no-row

Conversation

@tyrsson

@tyrsson tyrsson commented Oct 3, 2026 •

Copy link
Copy Markdown
Member

Follow-up to #10. NoRecordExists now uses the same falsy test as RecordExists, so null, false (PDO) and [] all mean no record. The false-to-null rewrite in AbstractDbValidator::query() from #10 is reverted as no longer needed.

Tests: one data-provided test per validator covers the three no-row shapes (null, false, []); it replaces the false-only test from #10 and adds the RecordExists counterpart. Against the merged 0.1.x the [] case fails on NoRecordExists (1 failure); with this change all pass.

composer test: 40 tests, 55 assertions, OK. Mago format and lint clean.

Signed-off-by: Joey Smith <jsmith@webinertia.net>
@tyrsson
tyrsson merged commit a59d395 into 0.1.x Oct 3, 2026
18 checks passed
@tyrsson
tyrsson deleted the fix/falsy-no-row branch October 3, 2026 13:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant