'RootQuery', 'toType' => 'PaymentGateway', 'fromFieldName' => 'paymentGateways', 'connectionArgs' => self::get_connection_args(), 'resolve' => function ( $source, $args, $context, $info ) { return Factory::resolve_payment_gateway_connection( $source, $args, $context, $info ); }, ); return array_merge( $defaults, $args ); } /** * Returns array of where args * * @return array */ public static function get_connection_args() { return array( 'all' => array( 'type' => 'Boolean', 'description' => __( 'Include disabled payment gateways?', 'wp-graphql-woocommerce' ), ), ); } }