Skip to content

Commit 5dd69d2

Browse files
committed
- fix undefined variables
1 parent 6f03906 commit 5dd69d2

File tree

1 file changed

+13
-14
lines changed

1 file changed

+13
-14
lines changed

src/Data/Connection/AbstractConnectionResolver.php

Lines changed: 13 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,6 @@ public function __construct( $source, array $args, AppContext $context, ResolveI
158158
*/
159159
$this->args = $args;
160160

161-
162161
}
163162

164163
/**
@@ -879,7 +878,19 @@ public function execute_and_get_ids() {
879878
*
880879
* @since 1.11.0
881880
*/
882-
$this->args = apply_filters( 'graphql_connection_args', $this->get_args(), $this, $args );
881+
$this->args = apply_filters( 'graphql_connection_args', $this->get_args(), $this, $this->args );
882+
883+
/**
884+
* Get the Query Args. This accepts the input args and maps it to how it should be
885+
* used in the WP_Query
886+
*
887+
* Filters the args
888+
*
889+
* @param array<string,mixed> $query_args The query args to be used with the executable query to get data.
890+
* @param \WPGraphQL\Data\Connection\AbstractConnectionResolver $connection_resolver Instance of the ConnectionResolver
891+
* @param array<string,mixed> $unfiltered_args Array of arguments input in the field as part of the GraphQL query.
892+
*/
893+
$this->query_args = apply_filters( 'graphql_connection_query_args', $this->get_query_args(), $this, $this->args );
883894

884895
/**
885896
* Determine the query amount for the resolver.
@@ -893,18 +904,6 @@ public function execute_and_get_ids() {
893904
*/
894905
$this->query_amount = $this->get_query_amount();
895906

896-
/**
897-
* Get the Query Args. This accepts the input args and maps it to how it should be
898-
* used in the WP_Query
899-
*
900-
* Filters the args
901-
*
902-
* @param array<string,mixed> $query_args The query args to be used with the executable query to get data.
903-
* @param \WPGraphQL\Data\Connection\AbstractConnectionResolver $connection_resolver Instance of the ConnectionResolver
904-
* @param array<string,mixed> $unfiltered_args Array of arguments input in the field as part of the GraphQL query.
905-
*/
906-
$this->query_args = apply_filters( 'graphql_connection_query_args', $this->get_query_args(), $this, $args );
907-
908907
/**
909908
* If should_execute is explicitly set to false already, we can
910909
* prevent execution quickly. If it's not, we need to

0 commit comments

Comments
 (0)