Skip to content

Commit 0c3f1a2

Browse files
committed
fix: specify parameter types and nullable callable syntax in Model @phpstan-method annotations
1 parent 39e6884 commit 0c3f1a2

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎system/Model.php‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,8 +84,8 @@
8484
* @method $this whereIn(?string $key = null, $values = null, ?bool $escape = null)
8585
* @method $this whereNotIn(?string $key = null, $values = null, ?bool $escape = null)
8686
*
87-
* @phpstan-method $this when($condition, callable(BaseBuilder, mixed): mixed $callback, (callable(BaseBuilder): mixed)|null $defaultCallback = null)
88-
* @phpstan-method $this whenNot($condition, callable(BaseBuilder, mixed): mixed $callback, (callable(BaseBuilder): mixed)|null $defaultCallback = null)
87+
* @phpstan-method $this when(mixed $condition, callable(BaseBuilder $builder, mixed $value): mixed $callback, ?callable(BaseBuilder $builder): mixed $defaultCallback = null)
88+
* @phpstan-method $this whenNot(mixed $condition, callable(BaseBuilder $builder, mixed $value): mixed $callback, ?callable(BaseBuilder $builder): mixed $defaultCallback = null)
8989
* @phpstan-import-type row_array from BaseModel
9090
*/
9191
class Model extends BaseModel

0 commit comments

Comments
 (0)