From 602a83d6f1ac630b0abf6732375643b48f1b38db Mon Sep 17 00:00:00 2001 From: Grace Noah Date: Mon, 12 Nov 2018 18:30:32 +0000 Subject: [PATCH] make ctx method resolvers concurrent --- codegen/object.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/codegen/object.go b/codegen/object.go index 70a1e99ecbc..656af297a07 100644 --- a/codegen/object.go +++ b/codegen/object.go @@ -104,7 +104,10 @@ func (f *Field) IsVariable() bool { } func (f *Field) IsConcurrent() bool { - return f.IsResolver() && !f.Object.DisableConcurrency + if f.Object.DisableConcurrency { + return false + } + return f.MethodHasContext || f.IsResolver() } func (f *Field) GoNameExported() string {