diff --git a/en/development/dependency-injection.rst b/en/development/dependency-injection.rst index 2e1c8306ce..4dfe8ef18c 100644 --- a/en/development/dependency-injection.rst +++ b/en/development/dependency-injection.rst @@ -93,13 +93,14 @@ Component Example :: // In src/Controller/Component/SearchComponent.php - class SearchComponent extends Command + class SearchComponent extends Component { public function __construct( ComponentRegistry $registry, - private UserService $users + private UserService $users, + array $config = [] ) { - parent::__construct($registry, []); + parent::__construct($registry, $config); } public function something()