Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: replace types mixed at Validation\StrictRules\Rule. #6643

Merged

Conversation

ping-yee
Copy link
Contributor

@ping-yee ping-yee commented Oct 7, 2022

Description
See #6310

If there is if (! is_string($value)) judgement, I chagned the type mixed to array|bool|float|int|object|string|null.
If there isn't the judgement of non-string, I changed the type string|null.

Checklist:

  • Securely signed commits
  • Component(s) with PHPDoc blocks, only if necessary or adds value
  • Unit testing, with >80% coverage
  • User guide updated
  • Conforms to style guide

@kenjis kenjis changed the title docs: replace types mixed at Validation\StrictRules\Rule.php. docs: replace types mixed at Validation\StrictRules\Rule. Oct 7, 2022
@kenjis
Copy link
Member

kenjis commented Oct 9, 2022

If there isn't the judgement of non-string, I changed the type string|null.

I don't understand why.
Attackers can send non-string values as JSON.

@ping-yee
Copy link
Contributor Author

I got it.
I'll change that.

@paulbalandan paulbalandan merged commit fd3b230 into codeigniter4:develop Oct 11, 2022
@paulbalandan
Copy link
Member

Thank you, @ping-yee

@ping-yee ping-yee deleted the docs-strictRule-rule-mixed branch October 11, 2022 04:12
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.

3 participants