Skip to content

phpdoc for Arrays::invoke() callables params#336

Open
spaze wants to merge 8 commits intonette:masterfrom
spaze:spaze/phpdoc-arrays-invoke-callables
Open

phpdoc for Arrays::invoke() callables params#336
spaze wants to merge 8 commits intonette:masterfrom
spaze:spaze/phpdoc-arrays-invoke-callables

Conversation

@spaze
Copy link

@spaze spaze commented Feb 13, 2026

  • bug fix / new feature? bug fix
  • BC break? no

Adds phpdoc params to $callbacks for Arrays::invoke(). Without the params PHPStan fails with errors like

Parameter #​1 $callbacks of static method Nette\Utils\Arrays::invoke() expects iterable<callable(): mixed>, array<callable(MichalSpacekCz\Form\UiForm, mixed): void> given.

(I wanted to use the 4.1.2 tag as a base ref for this PR, but there's no branch and GitHub doesn't let me create a PR when I select the tag as a base ref, so the base ref is the master branch but only for the PR, not for my branch. The change which added the line I'm changing is not in master. I'm not a git expert, not exactly sure what's going on here, sorry)

@dg dg force-pushed the master branch 6 times, most recently from 7c0abb7 to bb3ea63 Compare February 13, 2026 03:06
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.

2 participants