Skip to content

Warn if duplicate CommandHandlers are registred for same type. #9

@NickJosevski

Description

@NickJosevski

In EventfulHandlers
CommandHandlers : Map<string, EventfulCommandHandler<CommandResult<'TBaseEvent, 'TMetadata>, 'TCommandContext, 'TMetadata>>

AddCommandHandler will quietly replace the any existing command handler with an subsequent one with the same name. A warning would be sufficient then actions can be taken to create different naming for those commands.

In contrast AddEventHandler does cater for multiple using Map.insertWith List.append evtName [handler]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions