public virtual async Task <TEntity> QuerySingleAsync(IRepositoryQuery <TEntity> query, CancellationToken cancellation = default)
 {
     return(await query.ProjectTo(this.context.Set <TEntity>()).Where(query.GetQuery()).FirstOrDefaultAsync(cancellation).ConfigureAwait(false));
 }
 public virtual async Task <IEnumerable <TEntity> > QueryAsync(IRepositoryQuery <TEntity> query, CancellationToken cancellation = default)
 {
     return(await query.ProjectTo(this.context.Set <TEntity>()).Where(query.GetQuery()).ToListAsync(cancellation).ConfigureAwait(false));
 }