limbo-works / Limbo.Umbraco.ModelsBuilder

Custom models builder for Umbraco.
MIT License
4 stars 3 forks source link

Models generator doesn't detect classes in partial classes using file-scoped namespaces #18

Closed abjerner closed 1 year ago

abjerner commented 1 year ago

https://github.com/limbo-works/Limbo.Umbraco.ModelsBuilder/blob/v2/main/src/Limbo.Umbraco.ModelsBuilder/CodeAnalasis/FileSummary.cs#L93

Regular block-scoped namespaces are represented by the NamespaceDeclarationSyntax class, whereas the new file-scoped namespaces are represented by the FileScopedNamespaceDeclarationSyntax class. Both extend the BaseNamespaceDeclarationSyntax class, so we should ideally look for this one instead.