From fd99a817050eb286e20c1c48a3f6788e72f42c10 Mon Sep 17 00:00:00 2001 From: Shane32 Date: Tue, 20 Aug 2024 01:18:10 -0400 Subject: [PATCH] Update sample --- Sample/DoNotMapClrTypeAttribute.cs | 10 ---------- Sample/GraphTypes/MutationType.cs | 2 +- Sample/RequiredAttribute.cs | 8 -------- Sample/Sample.csproj | 4 ---- 4 files changed, 1 insertion(+), 23 deletions(-) delete mode 100644 Sample/DoNotMapClrTypeAttribute.cs delete mode 100644 Sample/RequiredAttribute.cs diff --git a/Sample/DoNotMapClrTypeAttribute.cs b/Sample/DoNotMapClrTypeAttribute.cs deleted file mode 100644 index 7f6a87d..0000000 --- a/Sample/DoNotMapClrTypeAttribute.cs +++ /dev/null @@ -1,10 +0,0 @@ -namespace Sample; - -/// -/// Indicates that GetClrTypeMappings should -/// skip this class when scanning an assembly for CLR type mappings. -/// -[AttributeUsage(AttributeTargets.Class, AllowMultiple = false, Inherited = true)] -public class DoNotMapClrTypeAttribute : Attribute -{ -} diff --git a/Sample/GraphTypes/MutationType.cs b/Sample/GraphTypes/MutationType.cs index 7d0c838..b2b2995 100644 --- a/Sample/GraphTypes/MutationType.cs +++ b/Sample/GraphTypes/MutationType.cs @@ -15,7 +15,7 @@ public Mutation(TodoDbContext db) _db = db; } - public async Task AddTodoAsync([Required] string title, string notes, CancellationToken cancellationToken) + public async Task AddTodoAsync(string title, string notes, CancellationToken cancellationToken) { var todo = new Todo { Title = title, diff --git a/Sample/RequiredAttribute.cs b/Sample/RequiredAttribute.cs deleted file mode 100644 index ba102fc..0000000 --- a/Sample/RequiredAttribute.cs +++ /dev/null @@ -1,8 +0,0 @@ -using GraphQL.Types; - -namespace Sample; - -public class RequiredAttribute : GraphQL.GraphQLAttribute -{ - public override void Modify(TypeInformation typeInformation) => typeInformation.IsNullable = false; -} diff --git a/Sample/Sample.csproj b/Sample/Sample.csproj index 2dfb55c..ccfcdbc 100644 --- a/Sample/Sample.csproj +++ b/Sample/Sample.csproj @@ -17,8 +17,4 @@ - - - -