mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-06-28 06:10:09 +00:00
Multisite: Provide $join as a possible SQL clause to the sites_clauses filter.
Previously, `compact()` provided a non existent `$join` and could cause confusion for anyone attempting to extend `WP_Site_Query` with their own tables. This aligns with the current behavior in `WP_Network_Query`. Props johnjamesjacoby. Fixes #37922. git-svn-id: https://develop.svn.wordpress.org/trunk@38631 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -514,6 +514,8 @@ class WP_Site_Query {
|
||||
$this->sql_clauses['where']['date_query'] = preg_replace( '/^\s*AND\s*/', '', $this->date_query->get_sql() );
|
||||
}
|
||||
|
||||
$join = '';
|
||||
|
||||
$where = implode( ' AND ', $this->sql_clauses['where'] );
|
||||
|
||||
$pieces = array( 'fields', 'join', 'where', 'orderby', 'limits', 'groupby' );
|
||||
|
||||
Reference in New Issue
Block a user