Exemple #1
0
        protected virtual async Task Notify <TNotification>(Guid chatId, TNotification notification)
            where TNotification : INotification
        {
            if (NotificationSender.SupportNotifyChatParticipants)
            {
                await NotificationSender.NotifyChatParticipants(notification, chatId).ConfigureAwait(false);
            }
            else
            {
                var chatUsers = await NotificationRouteService.GetChatUsers(chatId).ConfigureAwait(false);

                await NotificationSender.NotifyUsers(notification, chatUsers).ConfigureAwait(false);
            }
        }