Skip to content

Conversation

samsonasik
Copy link
Member

Description

Add @param array<> docblock based on its array dim fetch. This use mixed item type if it can pass mixed data.

Checklist:

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

@samsonasik
Copy link
Member Author

Ready to merge 👍

}

/**
* @param array<string, mixed> $data
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For tests, I think mixed is allowed. For callbacks, there are types in BaseModel, if you've forgotten or simplified it on purpose.

And what about the other methods with arrays? afterFindMethod beforeDeleteMethod...

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it use mixed item already, with string key.

This PR only change when there is an array dim fetch $param[key] in the method.

@samsonasik
Copy link
Member Author

Let's merge 👍

@samsonasik samsonasik merged commit 52d16f8 into codeigniter4:develop Oct 1, 2025
47 checks passed
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