Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 430c6d7

Browse files
committed
merged branch Tobion/console-event (PR #8038)
This PR was merged into the master branch. Discussion ---------- [Console] ensure integer exit codes in events | Q | A | ------------- | --- | Bug fix? | yes | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | License | MIT Commits ------- fe1db71 [Console] ensure integer exit codes in events
2 parents b51de93 + fe1db71 commit 430c6d7

File tree

3 files changed

+2
-6
lines changed

3 files changed

+2
-6
lines changed

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

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,6 @@
1111

1212
namespace Symfony\Component\Console\Event;
1313

14-
use Symfony\Component\Console\Command\Command;
15-
use Symfony\Component\Console\Input\InputInterface;
16-
use Symfony\Component\Console\Output\OutputInterface;
17-
1814
/**
1915
* Allows to do things before the command is executed.
2016
*

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public function __construct(Command $command, InputInterface $input, OutputInter
3030
parent::__construct($command, $input, $output);
3131

3232
$this->setException($exception);
33-
$this->exitCode = $exitCode;
33+
$this->exitCode = (int) $exitCode;
3434
}
3535

3636
/**

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ public function __construct(Command $command, InputInterface $input, OutputInter
4343
*/
4444
public function setExitCode($exitCode)
4545
{
46-
$this->exitCode = $exitCode;
46+
$this->exitCode = (int) $exitCode;
4747
}
4848

4949
/**

0 commit comments

Comments
 (0)