示例#1
0
        public async Task <Playlist> CreatePlaylistWithReturn(Playlist playlist, int userId)
        {
            var user = await _identityRepository.GetUser(userId);

            playlist.Owner = user ?? throw new TypedException(ExceptionType.BadRequest);
            return(await _playlistRepository.CreatePlaylistWithReturn(playlist, userId));
        }