Skip to content

Commit

Permalink
Merge pull request wp-graphql#3193 from wp-graphql/release/v1.28.1
Browse files Browse the repository at this point in the history
release: v1.28.1
  • Loading branch information
jasonbahl authored Aug 21, 2024
2 parents e6983cd + 46996cb commit 6516f75
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 5 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Changelog

## 1.28.1

### Chores / Bugfixes

- [#3189](https://github.com/wp-graphql/wp-graphql/pull/3189): fix: [regression] missing placeholder in $wpdb->prepare() call

## 1.28.0

### Upgrade Notice
Expand Down
2 changes: 1 addition & 1 deletion constants.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ function graphql_setup_constants() {

// Plugin version.
if ( ! defined( 'WPGRAPHQL_VERSION' ) ) {
define( 'WPGRAPHQL_VERSION', '1.28.0' );
define( 'WPGRAPHQL_VERSION', '1.28.1' );
}

// Plugin Folder Path.
Expand Down
8 changes: 7 additions & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Tags: GraphQL, Headless, REST API, Decoupled, React
Requires at least: 5.0
Tested up to: 6.6
Requires PHP: 7.1
Stable tag: 1.28.0
Stable tag: 1.28.1
License: GPL-3
License URI: https://www.gnu.org/licenses/gpl-3.0.html

Expand Down Expand Up @@ -282,6 +282,12 @@ Composer dependencies are no longer versioned in Github. Recommended install sou

== Changelog ==

= 1.28.1 =

**Chores / Bugfixes**

- [#3189](https://github.com/wp-graphql/wp-graphql/pull/3189): fix: [regression] missing placeholder in $wpdb->prepare() call

= 1.28.0 =

**Upgrade Notice**
Expand Down
4 changes: 3 additions & 1 deletion src/Data/Loader/UserLoader.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,9 @@ public function get_public_users( array $keys ) {

$results = $wpdb->get_results( // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching
$wpdb->prepare(
"SELECT DISTINCT $wpdb->users.ID FROM $wpdb->posts INNER JOIN $wpdb->users ON post_author = $wpdb->users.ID $where AND post_author IN ( $ids ) ORDER BY FIELD( $wpdb->users.ID, $ids)" // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPressVIPMinimum.Variables.RestrictedVariables.user_meta__wpdb__users
"SELECT DISTINCT $wpdb->users.ID FROM $wpdb->posts INNER JOIN $wpdb->users ON post_author = $wpdb->users.ID $where AND post_author IN ( %1\$s ) ORDER BY FIELD( $wpdb->users.ID, %2\$s)", // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.PreparedSQLPlaceholders.UnquotedComplexPlaceholder,WordPressVIPMinimum.Variables.RestrictedVariables.user_meta__wpdb__users
$ids,
$ids
)
);

Expand Down
4 changes: 2 additions & 2 deletions wp-graphql.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
* Description: GraphQL API for WordPress
* Author: WPGraphQL
* Author URI: http://www.wpgraphql.com
* Version: 1.28.0
* Version: 1.28.1
* Text Domain: wp-graphql
* Domain Path: /languages/
* Requires at least: 5.9
Expand All @@ -18,7 +18,7 @@
* @package WPGraphQL
* @category Core
* @author WPGraphQL
* @version 1.28.0
* @version 1.28.1
*/

// Exit if accessed directly.
Expand Down

0 comments on commit 6516f75

Please sign in to comment.