Skip to content

Commit 893409f

Browse files
[8.x] Fix schedule:work command Artisan binary name (#42083)
* Fix schedule:work command Artisan binary name * formatting Co-authored-by: Taylor Otwell <[email protected]>
1 parent f0d10fd commit 893409f

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/Illuminate/Console/Scheduling/ScheduleWorkCommand.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,11 @@ public function handle()
3838

3939
if (Carbon::now()->second === 0 &&
4040
! Carbon::now()->startOfMinute()->equalTo($lastExecutionStartedAt)) {
41-
$executions[] = $execution = new Process([PHP_BINARY, 'artisan', 'schedule:run']);
41+
$executions[] = $execution = new Process([
42+
PHP_BINARY,
43+
defined('ARTISAN_BINARY') ? ARTISAN_BINARY : 'artisan',
44+
'schedule:run'
45+
]);
4246

4347
$execution->start();
4448

0 commit comments

Comments
 (0)