alsami / MediatR.Extensions.Autofac.DependencyInjection

Autofac plug-in for MediatR.
MIT License
55 stars 14 forks source link

Callback registration for handlers #24

Closed marmeladhero closed 1 year ago

marmeladhero commented 1 year ago

I want to have option to register handlers with KeyFilter attribute. so I can register it like this:

builder.RegisterMediatR(
            MediatRConfigurationBuilder.Create(assembly)
                .WithAllOpenGenericHandlerTypesRegistered()
                .WithOpenGenericHandlerTypeToRegisterCallback(x => x.WithAttributeFiltering())
                .WithRegistrationScope(RegistrationScope.Scoped)
                .Build());

I know it can be done better 😞

alsami commented 1 year ago

I know it can be done better disappointed

I think it is good, thanks for the addition. A few minor things + tests and we should be good to go :)

marmeladhero commented 1 year ago

Check

alsami commented 1 year ago

Can you please squash your commits and add a nice commit message that describes the change. Thanks

marmeladhero commented 1 year ago

Am I done this correct?

alsami commented 1 year ago

You currently have six commits. You need to squash them into one commit.