Fixed generator issue

This commit is contained in:
Koen Bekkenutte
2021-05-31 04:35:52 +08:00
parent 980aaf7646
commit 99f3fd89f9
@@ -4,6 +4,7 @@ using Microsoft.CodeAnalysis.CSharp;
using Microsoft.CodeAnalysis.Text; using Microsoft.CodeAnalysis.Text;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Diagnostics;
using System.Linq; using System.Linq;
using System.Text; using System.Text;
using System.Threading; using System.Threading;
@@ -50,7 +51,7 @@ namespace EntityFrameworkCore.Projections.Generator
if (projectable.ClassNamespace is not null && projectable.ClassNamespace != projectable.TargetClassNamespace) if (projectable.ClassNamespace is not null && projectable.ClassNamespace != projectable.TargetClassNamespace)
{ {
var classUsingDirective = $"using {projectable.TargetClassNamespace};"; var classUsingDirective = $"using {projectable.ClassNamespace};";
if (!projectable.UsingDirectives.Contains(classUsingDirective)) if (!projectable.UsingDirectives.Contains(classUsingDirective))
{ {