-
Notifications
You must be signed in to change notification settings - Fork 2k
Closed
Labels
waiting for infoIssues or pull requests that need further clarification from the authorIssues or pull requests that need further clarification from the author
Description
PHP Version
8.1
CodeIgniter4 Version
4.2.5
CodeIgniter4 Installation Method
Composer (using codeigniter4/appstarter
)
Which operating systems have you tested for this bug?
macOS
Which server did you use?
apache
Database
No response
What happened?
trim() on null is not working for validation.
I suggest to edit: Validation.php Line 302:
$passed = $param === false ? $rule((string) $value ?? '') : $rule((string) $value ?? '', $param, $data);
Steps to Reproduce
make rule without a post.
Expected Output
Expected:\
Previous:
$passed = $param === false ? $rule($value) : $rule($value, $param, $data);
$passed = $param === false ? $rule((string) $value ?? '') : $rule((string) $value ?? '', $param, $data);
Anything else?
No response
Metadata
Metadata
Assignees
Labels
waiting for infoIssues or pull requests that need further clarification from the authorIssues or pull requests that need further clarification from the author