예제 #1
0
파일: FolderService.cs 프로젝트: HrMilev/PM
        public async Task DeleteAsync(int id, string userId)
        {
            var folder = _folderRepository
                         .GetList(x => x.CreatorId == userId && x.Id == id).FirstOrDefault();

            if (folder == null || folder.ParentFolderId == null)
            {
                return;
            }

            await _folderRepository.DeleteFolderAsync(id, userId);

            await _uploadedFileService.DeleteOrphanAsync(userId);
        }