wp-graphql / wp-graphql-tax-query

Adds `tax_query` support to postObject connection queries using WP_Query
46 stars 16 forks source link

Error when using RootQueryToShopItemConnectionWhereArgsTaxArray as a variable #35

Open vstrelianyi opened 1 year ago

vstrelianyi commented 1 year ago

I'm receiving the following error while running the query with variables

"Type loader is expected to return a callable or valid type \"RootQueryToShopItemConnectionWhereArgsTaxArray\", but it returned null"

the query to reproduce the issue:

query GET_SHOP_ITEMS_BY_CATS_TAGS($taxArray: [RootQueryToShopItemConnectionWhereArgsTaxArray]) { shop( where: {status: PUBLISH, taxQuery: {relation: AND, taxArray: $taxArray}, } ) { nodes { title databaseId uri } } }

query variables: { "taxArray": [{ "operator": "IN", "taxonomy": "SHOPCATEGORY", "terms": "grafika", "field": "SLUG"}] }