Subscription macros now correctly report unsupported attribute errors.

This commit is contained in:
Sunli 2020-11-07 09:13:53 +08:00
parent 29ec9dc204
commit 7816135f56

View File

@ -117,7 +117,7 @@ pub fn generate(
parse_graphql_attrs::<args::SubscriptionFieldArgument>(&pat.attrs)?
.unwrap_or_default(),
));
pat.attrs.clear();
remove_graphql_attrs(&mut pat.attrs);
}
(arg, Type::Reference(TypeReference { elem, .. })) => {
if let Type::Path(path) = elem.as_ref() {