Esempio n. 1
0
        public async Task <IList <NotificationSharedUser> > HandleAsync(GetSharedUsersByNotificationId message)
        {
            var sharedUsers = await repository.GetAllSharedUsers(message.NotificationId);

            return(sharedUsers
                   .Select(sharedUser => mapper.Map <NotificationSharedUser>(sharedUser))
                   .ToList());
        }
Esempio n. 2
0
        public async Task <bool> HandleAsync(CheckIfSharedUserExists message)
        {
            var sharedUsers = await repository.GetAllSharedUsers(message.NotificationId);

            return(sharedUsers.Any());
        }