Fix/sonarqube critical major debt #11

Merged
bermudalamb merged 10 commits from fix/sonarqube-critical-major-debt into main 2026-05-26 10:36:29 -05:00
3 changed files with 3 additions and 4 deletions
Showing only changes of commit 1124e91141 - Show all commits
View File
@@ -208,7 +208,7 @@ public class LinqQueryBreakdown : QueryBreakdown
{
// If the original expression can be converted to IQueryable<T>, use it
// Otherwise, we cannot safely reconstruct without the original query provider
if (OriginalExpression is Expression expr && EntityType == typeof(T))
if (OriginalExpression is Expression && EntityType == typeof(T))
{
// We have the expression, but we don't have the provider to create IQueryable<T>
// The breakdown analysis is one-way; reconstruction requires the original provider
@@ -275,8 +275,7 @@ public class LinqQueryBreakdown : QueryBreakdown
var breakdown = new Breakdowns.SqlServer.InsertBreakdown();
breakdown.TableName.Clause = typeof(T).Name;
// Use first entity to get column names
var firstEntity = entitiesList.First();
// Use the entity type to get column names
var properties = typeof(T).GetProperties();
var columnNames = new List<string>();
@@ -312,7 +312,7 @@ public class LinqExpressionVisitor : ExpressionVisitor
return GetFullMemberName(member);
}
if (expression is ParameterExpression param)
if (expression is ParameterExpression)
{
return "*";
}