From cdd33c7e2d7a49b53178f9baa32fffb51f88b247 Mon Sep 17 00:00:00 2001 From: Andrew Scott Date: Wed, 23 Oct 2024 14:32:03 -0700 Subject: [PATCH] fix: #483 be more specific about looking for entities in "Microsoft.*" namespaces --- src/IntelliTect.Coalesce/TypeUsage/DbContextTypeUsage.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/IntelliTect.Coalesce/TypeUsage/DbContextTypeUsage.cs b/src/IntelliTect.Coalesce/TypeUsage/DbContextTypeUsage.cs index 8706b276c..a00381ff2 100644 --- a/src/IntelliTect.Coalesce/TypeUsage/DbContextTypeUsage.cs +++ b/src/IntelliTect.Coalesce/TypeUsage/DbContextTypeUsage.cs @@ -19,7 +19,7 @@ public DbContextTypeUsage(ClassViewModel classViewModel) // as well as any props that aren't in the Microsoft namespace. // This prevents us from picking up things from Microsoft.AspNetCore.Identity.EntityFrameworkCore // that don't have keys & other properties that Coalesce can work with. - .Where(p => p.Parent.Equals(classViewModel) || !p.PureType.FullNamespace.StartsWith(nameof(Microsoft))) + .Where(p => p.Parent.Equals(classViewModel) || !p.PureType.FullNamespace.StartsWith(nameof(Microsoft) + ".")) .Where(p => p.Type.IsA(typeof(DbSet<>))) .Select(p => new EntityTypeUsage(this, p.PureType, p.Name))