From 0b0e4a91a0827c66fd3d6f6b5a58177be96ce860 Mon Sep 17 00:00:00 2001 From: matthew clemens Date: Sat, 9 Feb 2019 14:36:34 -0800 Subject: [PATCH] Fix directives on fields with custom scalars --- codegen/input.gotpl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/codegen/input.gotpl b/codegen/input.gotpl index 7345bf4fe16..c8ac7ad3a5d 100644 --- a/codegen/input.gotpl +++ b/codegen/input.gotpl @@ -35,7 +35,7 @@ if err != nil { return it, err } - if data, ok := tmp.({{ $field.TypeReference.GO }}) ; ok { + if data, ok := tmp.({{ $field.TypeReference.GO | ref }}) ; ok { it.{{$field.GoFieldName}} = data } else { return it, fmt.Errorf(`unexpected type %T from directive, should be {{ $field.TypeReference.GO }}`, tmp)