Skip to content

Commit caa7bcb

Browse files
committed
use GetType
1 parent 7f8d3fe commit caa7bcb

File tree

1 file changed

+2
-12
lines changed

1 file changed

+2
-12
lines changed

src/NHibernate/Loader/Criteria/CriteriaQueryTranslator.cs

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -778,18 +778,8 @@ public IType GetTypeUsingProjection(ICriteria subcriteria, string propertyName)
778778

779779
if (projectionTypes == null)
780780
{
781-
//it does not refer to an alias of a projection,
782-
//look for a property
783-
784-
if (TryGetType(subcriteria, propertyName, out var type))
785-
{
786-
return type;
787-
}
788-
if (outerQueryTranslator != null)
789-
{
790-
return outerQueryTranslator.GetTypeUsingProjection(subcriteria, propertyName);
791-
}
792-
throw new QueryException("Could not find property " + propertyName);
781+
//it does not refer to an alias of a projection, look for a property
782+
return GetType(subcriteria, propertyName);
793783
}
794784
else
795785
{

0 commit comments

Comments
 (0)