Skip to content

Commit

Permalink
Fixed migration issue (#79)
Browse files Browse the repository at this point in the history
  • Loading branch information
PascalSenn authored Apr 29, 2024
1 parent 217f6d6 commit 588ac7b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
6 changes: 1 addition & 5 deletions src/Server/src/GraphQL/Approval/ApprovalQueries.cs
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Threading;
using System.Threading.Tasks;
using HotChocolate;
using HotChocolate.AspNetCore.Authorization;
using HotChocolate.Authorization;
using HotChocolate.Resolvers;
using HotChocolate.Types;
Expand Down Expand Up @@ -67,7 +63,7 @@ internal class ResourceApprovalResolvers
IResolverContext context,
CancellationToken cancellationToken)
{
var selections = context.GetSelections((ObjectType)context.ObjectType);
var selections = context.GetSelections((ObjectType)context.Selection.Type.NamedType());

if (selections is { Count: 1 } && selections[0].Field.Name is "id")
{
Expand Down
2 changes: 1 addition & 1 deletion src/Server/src/GraphQL/Publishing/PublishQueries.cs
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ internal class PublishedResourceResolvers
IResolverContext context,
CancellationToken cancellationToken)
{
var selections = context.GetSelections((ObjectType)context.ObjectType);
var selections = context.GetSelections((ObjectType)context.Selection.Type.NamedType());

if (selections is { } s && s.Count() == 1 && s[0].Field.Name == "id")
{
Expand Down

0 comments on commit 588ac7b

Please sign in to comment.