Skip to content

Commit c479995

Browse files
committed
feat(cmd.action): bind to $this
1 parent 2bf08c5 commit c479995

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Input/Command.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -413,7 +413,7 @@ public function action(callable $action = null)
413413
return $this->_action;
414414
}
415415

416-
$this->_action = $action;
416+
$this->_action = $action ? \Closure::bind($action, $this) : null;
417417

418418
return $this;
419419
}

0 commit comments

Comments
 (0)