File tree 1 file changed +4
-4
lines changed
src/JsonApiDotNetCore/Queries/Internal/QueryableBuilding
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -136,10 +136,10 @@ private ICollection<PropertySelector> ToPropertySelectors(FieldSelectors fieldSe
136
136
137
137
if ( fieldSelectors . ContainsReadOnlyAttribute || fieldSelectors . ContainsOnlyRelationships )
138
138
{
139
- // If a read-only attribute is selected, its calculated value likely depends on another property, so select all properties.
140
- // And only selecting relationships implicitly means to select all attributes too .
139
+ // If a read-only attribute is selected, its calculated value likely depends on another property, so fetch all scalar properties.
140
+ // And only selecting relationships implicitly means to fetch all scalar properties as well .
141
141
142
- IncludeAllAttributes ( elementType , propertySelectors ) ;
142
+ IncludeAllScalarProperties ( elementType , propertySelectors ) ;
143
143
}
144
144
145
145
IncludeFields ( fieldSelectors , propertySelectors ) ;
@@ -148,7 +148,7 @@ private ICollection<PropertySelector> ToPropertySelectors(FieldSelectors fieldSe
148
148
return propertySelectors . Values ;
149
149
}
150
150
151
- private void IncludeAllAttributes ( Type elementType , Dictionary < PropertyInfo , PropertySelector > propertySelectors )
151
+ private void IncludeAllScalarProperties ( Type elementType , Dictionary < PropertyInfo , PropertySelector > propertySelectors )
152
152
{
153
153
IEntityType entityModel = _entityModel . GetEntityTypes ( ) . Single ( type => type . ClrType == elementType ) ;
154
154
IEnumerable < IProperty > entityProperties = entityModel . GetProperties ( ) . Where ( property => ! property . IsShadowProperty ( ) ) . ToArray ( ) ;
You can’t perform that action at this time.
0 commit comments