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

Pass child expands and selects to the projector when expanding the Children field #456

Merged
merged 2 commits into from Sep 11, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
3 changes: 1 addition & 2 deletions src/Services/OData/ExpanderProjector.cs
Expand Up @@ -165,8 +165,7 @@ private void CheckSelectTree(List<Property> expandTree, List<Property> selectTre
: FilterStatus.Disabled;

return ProjectMultiRefContents(
c.Children.AsEnumerable().Select(cnt => cnt.ContentHandler),
new List<Property>(new[] { expansion }),
c.Children.AsEnumerable().Select(cnt => cnt.ContentHandler), expansion.Children,
property.Children);
});
break;
Expand Down
4 changes: 1 addition & 3 deletions src/Services/OData/SimpleExpanderProjector.cs
Expand Up @@ -107,9 +107,7 @@ internal override void Initialize(Content container)

var expansion = GetExpansion(ODataHandler.ChildrenPropertyName, expandTree);

return ProjectMultiRefContents(
c.Children.AsEnumerable().Select(cnt => cnt.ContentHandler),
new List<Property>(new[] { expansion }));
return ProjectMultiRefContents(c.Children.AsEnumerable().Select(cnt => cnt.ContentHandler), expansion.Children);
});

if (!outfields.ContainsKey(ICONPROPERTY))
Expand Down