Skip to content

Commit

Permalink
Merge pull request #337 from dereuromark/phpstan
Browse files Browse the repository at this point in the history
Fix up PHPStan
  • Loading branch information
dereuromark committed Dec 4, 2023
2 parents 33d8f43 + a45436c commit baafaeb
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
1 change: 0 additions & 1 deletion phpstan.neon
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ parameters:
bootstrapFiles:
- tests/bootstrap.php
- tests/shim.php
checkGenericClassInNonGenericObjectType: false
ignoreErrors:
- '#Unsafe usage of new static\(\).+#'
- '#Parameter \#1 \$object of function get_class expects object, object\|string given.#'
6 changes: 3 additions & 3 deletions src/Annotator/ModelAnnotator.php
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ protected function getAssociations(AssociationCollection $tableAssociations): ar
continue;
}

/** @var \Cake\ORM\Association\BelongsToMany $association */
/** @var \Cake\ORM\Association\BelongsToMany<\Cake\ORM\Table> $association */
$through = $this->throughAlias($association);
if (!$through) {
continue;
Expand All @@ -306,7 +306,7 @@ protected function getAssociations(AssociationCollection $tableAssociations): ar
}

/**
* @param \Cake\ORM\Association\BelongsToMany $association
* @param \Cake\ORM\Association\BelongsToMany<\Cake\ORM\Table> $association
* @return string
*/
protected function throughAlias(BelongsToMany $association): string {
Expand All @@ -328,7 +328,7 @@ protected function throughAlias(BelongsToMany $association): string {
/**
* @uses \Cake\ORM\Association\BelongsToMany::_junctionTableName()
*
* @param \Cake\ORM\Association\BelongsToMany $association
* @param \Cake\ORM\Association\BelongsToMany<\Cake\ORM\Table> $association
* @return string
*/
protected function junctionTableName(BelongsToMany $association): string {
Expand Down

0 comments on commit baafaeb

Please sign in to comment.