Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GenericRepository question #2

Open
gmbeas opened this issue Apr 28, 2021 · 0 comments
Open

GenericRepository question #2

gmbeas opened this issue Apr 28, 2021 · 0 comments

Comments

@gmbeas
Copy link

gmbeas commented Apr 28, 2021

Hi, I find your project interesting, I am trying to use it, but I have a question with this GenericRepository method,

public bool Exist(Expression<Func<TEntity, bool>> predicate) { return _baseDbContext.Set<TEntity>().Any(predicate); }

when I call it from BaseRepository, throws me an error
The best overloaded method match for 'Backend.Infrastructure.Repositories.GenericRepository<Backend.Models.Models.OrderModel,Backend.Data.Entities.Order>.Exist(System.Linq.Expressions.Expression<System.Func<Backend.Data.Entities.Order,bool>>)' has some invalid arguments

public bool Exist(Expression<Func<Object, bool>> predicate) { return _iGenericRepository.Exist(predicate); }

I would be very grateful if you can guide me
best regards

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant