From 404e5fe800c52d2eeea88316eb58638df30770ae Mon Sep 17 00:00:00 2001 From: iatsuta Date: Wed, 18 Feb 2026 11:39:29 +0100 Subject: [PATCH] upd FetchService --- src/GenericQueryable.Runtime/Fetching/FetchService.cs | 4 +++- src/__SolutionItems/CommonAssemblyInfo.cs | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/GenericQueryable.Runtime/Fetching/FetchService.cs b/src/GenericQueryable.Runtime/Fetching/FetchService.cs index 23110bd..9b7f882 100644 --- a/src/GenericQueryable.Runtime/Fetching/FetchService.cs +++ b/src/GenericQueryable.Runtime/Fetching/FetchService.cs @@ -52,11 +52,13 @@ private Expression, IQueryable>> GetApplyFetch var resultBody = this .GetFetchMethods(fetchPath).ZipStrong(fetchPath.Properties, (method, prop) => new { method, prop }) - .Aggregate(startState.Body, (state, pair) => Expression.Call(pair.method, state, pair.prop)); + .Aggregate(startState.Body, (state, pair) => Expression.Call(pair.method, state, this.GetFetchProperty(pair.prop))); return Expression.Lambda, IQueryable>>(resultBody, startState.Parameters); } + protected virtual LambdaExpression GetFetchProperty(LambdaExpression prop) => prop; + protected abstract IEnumerable GetFetchMethods(LambdaExpressionPath fetchPath) where TSource : class; } \ No newline at end of file diff --git a/src/__SolutionItems/CommonAssemblyInfo.cs b/src/__SolutionItems/CommonAssemblyInfo.cs index 86073b0..8fc631b 100644 --- a/src/__SolutionItems/CommonAssemblyInfo.cs +++ b/src/__SolutionItems/CommonAssemblyInfo.cs @@ -3,7 +3,7 @@ [assembly: AssemblyProduct("GenericQueryable")] [assembly: AssemblyCompany("IvAt")] -[assembly: AssemblyVersion("2.2.1.0")] +[assembly: AssemblyVersion("2.2.2.0")] [assembly: AssemblyInformationalVersion("changes at build")] #if DEBUG