@@ -72,13 +72,13 @@ function op_filter_graphql_connection_amount_requested($amount, $resolver)
72
72
*/
73
73
static function get_page_size (AbstractConnectionResolver $ resolver )
74
74
{
75
- $ args = $ resolver ->getArgs ();
75
+ $ args = $ resolver ->get_args ();
76
76
return intval ($ args ['where ' ]['offsetPagination ' ]['size ' ] ?? 0 );
77
77
}
78
78
79
79
static function is_offset_resolver (AbstractConnectionResolver $ resolver )
80
80
{
81
- $ args = $ resolver ->getArgs ();
81
+ $ args = $ resolver ->get_args ();
82
82
return isset ($ args ['where ' ]['offsetPagination ' ]);
83
83
}
84
84
@@ -90,7 +90,7 @@ function op_filter_graphql_connection_query_args(
90
90
$ query_args ,
91
91
AbstractConnectionResolver $ resolver
92
92
) {
93
- $ info = $ resolver ->getInfo ();
93
+ $ info = $ resolver ->get_info ();
94
94
$ selection_set = $ info ->getFieldSelection (2 );
95
95
96
96
if (!isset ($ selection_set ['pageInfo ' ]['offsetPagination ' ]['total ' ])) {
@@ -112,10 +112,10 @@ function op_filter_graphql_connection_query_args(
112
112
static function add_post_type_fields (\WP_Post_Type $ post_type_object )
113
113
{
114
114
$ type = ucfirst ($ post_type_object ->graphql_single_name );
115
- register_graphql_fields ("RootQueryTo $ { type}ConnectionWhereArgs " , [
115
+ register_graphql_fields ("RootQueryTo { $ type }ConnectionWhereArgs " , [
116
116
'offsetPagination ' => [
117
117
'type ' => 'OffsetPagination ' ,
118
- 'description ' => "Paginate $ { type}s with offsets " ,
118
+ 'description ' => "Paginate { $ type }s with offsets " ,
119
119
],
120
120
]);
121
121
}
@@ -126,7 +126,7 @@ function op_filter_graphql_connection_page_info(
126
126
) {
127
127
$ size = self ::get_page_size ($ resolver );
128
128
$ query = $ resolver ->get_query ();
129
- $ args = $ resolver ->getArgs ();
129
+ $ args = $ resolver ->get_args ();
130
130
$ offset = $ args ['where ' ]['offsetPagination ' ]['offset ' ] ?? 0 ;
131
131
132
132
$ total = null ;
0 commit comments