public async Task <Response> Handle(Request request, CancellationToken cancellationToken) => new Response() { Note = NoteDto.FromNote(await _context.Notes .Include(x => x.NoteTags) .ThenInclude(x => x.Tag) .SingleAsync(x => x.Slug == request.Slug)) };
public async Task <Response> Handle(Request request, CancellationToken cancellationToken) => new Response() { Notes = await _context.Notes .IgnoreQueryFilters() .Where(x => x.IsDeleted) .Select(x => NoteDto.FromNote(x, false)) .ToListAsync() };
public async Task <Response> Handle(Request request, CancellationToken cancellationToken) => new Response() { Notes = await _context.Notes.Select(x => NoteDto.FromNote(x, true)).ToListAsync() };
public async Task <Response> Handle(Request request, CancellationToken cancellationToken) => new Response() { Note = NoteDto.FromNote(await _context.Notes.FindAsync(request.NoteId)) };