Skip to content

Commit dfef227

Browse files
wouterjfabpot
authored andcommitted
Fixed exit code with non-integer throwable code
1 parent 0a95168 commit dfef227

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Symfony/Component/Console/Event/ConsoleErrorEvent.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,6 @@ public function setExitCode($exitCode)
7878
*/
7979
public function getExitCode()
8080
{
81-
return null !== $this->exitCode ? $this->exitCode : ($this->error->getCode() ?: 1);
81+
return null !== $this->exitCode ? $this->exitCode : (is_int($this->error->getCode()) ? $this->error->getCode() : 1);
8282
}
8383
}

0 commit comments

Comments
 (0)