Example #1
0
        public override async Task <Unit> Handle(QuoteCommandAction request, CancellationToken cancellationToken)
        {
            var image = await _inspiroService.GetInspiroImage(cancellationToken);

            await Ctx.Client.SendPhotoAsync(Ctx.GetTelegramChat(), image, cancellationToken : cancellationToken);

            return(Unit.Value);
        }
    public override async Task <Status> Handle(QuoteCommandAction action, CancellationToken cancellationToken)
    {
        var image = await _inspiroService.GetInspiroImage(cancellationToken);

        await NavigatorContext.GetTelegramClient().SendPhotoAsync(NavigatorContext.GetTelegramChat() !, image, cancellationToken: cancellationToken);

        return(Success());
    }