Skip to content

Method injection CommandHandler #39

@reinvanleirsberghe

Description

@reinvanleirsberghe

Hey Jeffrey!

I am trying to do method injection in a CommandHandler class like so:
public function handle($command, \UserRepository $userRepository)

Still, I'm getting the following error:
Declaration of Site\Registration\RegisterUserCommandHandler::handle() must be compatible with Laracasts\Commander\CommandHandler::handle($command)

Is it even possible to do method injection here?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions