コード例 #1
0
ファイル: UserService.cs プロジェクト: GusLab/video-portal
        public async Task DeleteFollowerAsync(string userId, Follower follower)
        {
            var user = await _userRepository.GetAsync(userId);
            if (user == null)
            {
                throw new NotFoundException(string.Format("Could not find user '{0}'.", userId));
            }

            await _userRepository.DeleteFollowerAsync(userId, _mapper.Map<Follower, FollowerEntity>(follower));
        }
コード例 #2
0
ファイル: UserService.cs プロジェクト: GusLab/video-portal
 public Task AddFollowerAsync(string userId, Follower follower)
 {
     return _userRepository.AddFollowerAsync(userId, _mapper.Map<Follower, FollowerEntity>(follower));
 }