constellation-api/CH.CQRS/Command/User/ServiceCollectionExtension.cs

15 lines
492 B
C#
Raw Normal View History

using Microsoft.Extensions.DependencyInjection;
using OpenHarbor.CQRS.FluentValidation;
namespace CH.CQRS.Command.User;
public static class ServiceCollectionExtension
{
public static IServiceCollection AddUserCommand(this IServiceCollection services)
{
services.AddCommand<UpdateNameCommand, UpdateNameCommandHandler, UpdateNameCommandValidator>();
services.AddCommand<UpdateEmailCommand, UpdateEmailCommandHandler, UpdateEmailCommandValidator>();
return services;
}
}