public static async Task <TEntity> SomeUserRepositoryMethod <TEntity>(this IExtensionRepository <TEntity> self) where TEntity : UserModel { return(await self.GetAll().FirstOrDefaultAsync(model => model.IsTestBoolProperty)); }
public static TEntity[] GetActive <TEntity>(this IExtensionRepository <TEntity> self) where TEntity : IActive, IModel { return(self.GetAll().Where(entity => entity.IsActive).ToArray()); }