diff --git a/sample/Sample.Api/Sample.Api.csproj b/sample/Sample.Api/Sample.Api.csproj
index e9da122..118a418 100644
--- a/sample/Sample.Api/Sample.Api.csproj
+++ b/sample/Sample.Api/Sample.Api.csproj
@@ -6,11 +6,11 @@
-
-
-
-
-
+
+
+
+
+
diff --git a/src/SmartWhere/SmartWhere.cs b/src/SmartWhere/SmartWhere.cs
index 923edda..26ca4dc 100644
--- a/src/SmartWhere/SmartWhere.cs
+++ b/src/SmartWhere/SmartWhere.cs
@@ -24,7 +24,7 @@ public static IQueryable Where(this IQueryable source, IWhereClause whe
{
var whereClauseProperties = whereClauseDto.GetWhereClauseProperties(out var valueData);
- if (whereClauseProperties.IsNullOrNotAny())
+ if (whereClauseProperties.IsNullOrNotAny() || valueData.IsNull())
return source.Where(x => true);
Expression comparison = null;
@@ -195,7 +195,6 @@ private static Expression ComplexComparison(
foreach (var (propertyInfo, propertyType) in properties)
{
-
if (!propertyType.Namespace!.StartsWith("System") ||
propertyInfo.PropertyType!.IsEnumarableType())
{
@@ -290,9 +289,7 @@ private static MemberExpression SetLastMember(
Expression parameterExpression)
{
if (lastMember.IsNull())
- {
return Expression.Property(baseParameter, propertyInfo.Name);
- }
return currentType.IsEnumarableType()
? Expression.MakeMemberAccess(parameterExpression, propertyInfo)
@@ -312,9 +309,7 @@ private static ParameterExpression SetParameterExpression(
ParameterExpression parameterExpression)
{
if (currentType.IsEnumarableType())
- {
return Expression.Parameter(type!, type!.Name.ToLower());
- }
return parameterExpression.IsNull()
? Expression.Parameter(type, type.Name.ToLower())
diff --git a/src/SmartWhere/SmartWhere.csproj b/src/SmartWhere/SmartWhere.csproj
index b11db03..5016363 100644
--- a/src/SmartWhere/SmartWhere.csproj
+++ b/src/SmartWhere/SmartWhere.csproj
@@ -2,7 +2,7 @@
SmartWhere
- 2.2.1
+ 2.2.2
Barış Yerlikaya
Barış Yerlikaya
SmartWhere
diff --git a/tests/SmartWhere.Tests/SmartWhere.Test.csproj b/tests/SmartWhere.Tests/SmartWhere.Test.csproj
index c276328..876a622 100644
--- a/tests/SmartWhere.Tests/SmartWhere.Test.csproj
+++ b/tests/SmartWhere.Tests/SmartWhere.Test.csproj
@@ -8,9 +8,9 @@
-
-
-
+
+
+
runtime; build; native; contentfiles; analyzers; buildtransitive
all