using Domain.Config; namespace Application.Common.Base; public abstract class RequestHandlerBase: IRequestHandlerWrapper where TIn : IRequestWrapper { protected ICardDbContext CardDbContext { get; } protected IMusicDbContext MusicDbContext { get; } protected GameConfig Config { get; } public RequestHandlerBase(ICardDependencyAggregate aggregate) { CardDbContext = aggregate.CardDbContext; MusicDbContext = aggregate.MusicDbContext; Config = aggregate.Options.Value; } public abstract Task> Handle(TIn request, CancellationToken cancellationToken); }