From cb0738b34957f9d6ee092ef76856bc1f99a4b0f1 Mon Sep 17 00:00:00 2001 From: Peter Sanchez Date: Mon, 12 Aug 2024 18:20:48 -0600 Subject: [PATCH] Working around updated gqlclient error wrapping changes --- client.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/client.go b/client.go index 8514f6f..8384120 100644 --- a/client.go +++ b/client.go @@ -41,6 +41,10 @@ func Execute(ctx context.Context, op *gqlclient.Operation, result interface{}) e client = gqlclient.New(origin, httpClient) err := client.Execute(ctx, op, &result) + if graphErrors, ok := err.(interface{ Unwrap() []error }); ok { + errs := graphErrors.Unwrap() + err = errs[0] + } return err } -- 2.45.2