diff --git a/src/ParallelError.php b/src/ParallelError.php index 83c68ca4..b0c62b2c 100644 --- a/src/ParallelError.php +++ b/src/ParallelError.php @@ -6,7 +6,7 @@ class ParallelError extends Exception { - public static function fromException($exception): ParallelError + public static function fromException($exception): self { return new self($exception); } diff --git a/src/ParallelProcess.php b/src/ParallelProcess.php index 71ec687f..592b0e4a 100644 --- a/src/ParallelProcess.php +++ b/src/ParallelProcess.php @@ -2,7 +2,6 @@ namespace Spatie\Async; -use Error; use Throwable; use Symfony\Component\Process\Process; use Spatie\Async\Output\SerializableException; @@ -142,7 +141,7 @@ public function triggerSuccess() if ($this->getErrorOutput()) { $this->triggerError(); - return null; + return; } $output = $this->getOutput();