Skip to content

Commit

Permalink
Fixing PHPStan level 9 issues
Browse files Browse the repository at this point in the history
  • Loading branch information
gplanchat committed Nov 14, 2023
1 parent 2e71ef5 commit ef2b850
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/RunnableInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@

use Kiboko\Contract\Satellite\RunnableInterface as SatelliteRunableInterface;

/** @deprecated Use \Kiboko\Contract\Job\RunnableInterface instead */
/** @deprecated Use \Kiboko\Contract\Satellite\RunnableInterface instead */
interface RunnableInterface extends SatelliteRunableInterface {}
2 changes: 2 additions & 0 deletions src/SchedulingInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

namespace Kiboko\Contract\Pipeline;

use Kiboko\Contract\Satellite\RunnableInterface;

interface SchedulingInterface
{
public function job(RunnableInterface $job): self;
Expand Down
7 changes: 5 additions & 2 deletions src/StepRejectionInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,14 @@

namespace Kiboko\Contract\Pipeline;

/**
* @template Type
*/
interface StepRejectionInterface
{
/** @param non-empty-array<mixed>|object $rejection */
/** @param Type $rejection */
public function reject(array|object $rejection, \Throwable $exception = null): void;

Check failure on line 13 in src/StepRejectionInterface.php

View workflow job for this annotation

GitHub Actions / phpstan

Method Kiboko\Contract\Pipeline\StepRejectionInterface::reject() has parameter $rejection with no value type specified in iterable type array.

Check failure on line 13 in src/StepRejectionInterface.php

View workflow job for this annotation

GitHub Actions / phpstan

PHPDoc tag @param for parameter $rejection with type Type is not subtype of native type array|object.

/** @param non-empty-array<array-key, mixed>|object $rejection */
/** @param Type $rejection */
public function rejectWithReason(array|object $rejection, string $reason, \Throwable $exception = null): void;
}

0 comments on commit ef2b850

Please sign in to comment.