Handler.cs 423 B

12345678910111213
  1. using Application.Abstractions.Messaging;
  2. using Application.Abstractions.News;
  3. namespace Application.Features.Admin.Crypto.News.Source.ForceFetch
  4. {
  5. public sealed class Handler(IRssCollector rssCollector) : ICommandHandler<Command, int>
  6. {
  7. public async Task<int> Handle(Command request, CancellationToken ct)
  8. {
  9. return await rssCollector.FetchSourceAsync(request.ID, ct);
  10. }
  11. }
  12. }