Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/wp-includes/class-wp-scripts.php
Original file line number Diff line number Diff line change
Expand Up @@ -1156,6 +1156,7 @@ private function get_highest_fetchpriority_with_dependents( string $handle, arra
$fetchpriority = 'auto';
}

/** @var string[] $priorities */
static $priorities = array(
'low',
'auto',
Expand Down
3 changes: 3 additions & 0 deletions src/wp-includes/class-wp-tax-query.php
Original file line number Diff line number Diff line change
Expand Up @@ -371,6 +371,7 @@ protected function get_sql_for_query( &$query, $depth = 0 ) {
*
* @param array $clause Query clause (passed by reference).
* @param array $parent_query Parent query array.
* @param-out array|WP_Error $clause
* @return array {
* Array containing JOIN and WHERE SQL clauses to append to a first-order query.
*
Expand Down Expand Up @@ -539,6 +540,7 @@ protected function find_compatible_table_alias( $clause, $parent_query ) {
* @since 3.2.0
*
* @param array $query The single query. Passed by reference.
* @param-out array|WP_Error $query
*/
private function clean_query( &$query ) {
if ( empty( $query['taxonomy'] ) ) {
Expand Down Expand Up @@ -589,6 +591,7 @@ private function clean_query( &$query ) {
* @param array $query The single query. Passed by reference.
* @param string $resulting_field The resulting field. Accepts 'slug', 'name', 'term_taxonomy_id',
* or 'term_id'. Default 'term_id'.
* @param-out array|WP_Error $query
*/
public function transform_query( &$query, $resulting_field ) {
if ( empty( $query['terms'] ) ) {
Expand Down
6 changes: 3 additions & 3 deletions src/wp-includes/post.php
Original file line number Diff line number Diff line change
Expand Up @@ -6697,9 +6697,9 @@ function get_page_hierarchy( &$pages, $page_id = 0 ) {
*
* @see _page_traverse_name()
*
* @param int $page_id Page ID.
* @param array $children Parent-children relations (passed by reference).
* @param string[] $result Array of page names keyed by ID (passed by reference).
* @param int $page_id Page ID.
* @param WP_Post[][] $children Parent-children relations (passed by reference).
* @param string[] $result Array of page names keyed by ID (passed by reference).
*/
function _page_traverse_name( $page_id, &$children, &$result ) {
if ( isset( $children[ $page_id ] ) ) {
Expand Down
20 changes: 0 additions & 20 deletions tests/phpstan/baselines/parameterByRef.type.neon
Original file line number Diff line number Diff line change
Expand Up @@ -18,28 +18,8 @@

parameters:
ignoreErrors:
-
message: '#^Parameter &\$stored_results by\-ref type of method WP_Scripts\:\:get_highest_fetchpriority_with_dependents\(\) expects array\<string, string\>, array\<string, mixed\> given\.$#'
identifier: parameterByRef.type
count: 1
path: ../../../src/wp-includes/class-wp-scripts.php
-
message: '#^Parameter &\$query by\-ref type of method WP_Tax_Query\:\:clean_query\(\) expects array, WP_Error given\.$#'
identifier: parameterByRef.type
count: 2
path: ../../../src/wp-includes/class-wp-tax-query.php
-
message: '#^Parameter &\$query by\-ref type of method WP_Tax_Query\:\:transform_query\(\) expects array, WP_Error given\.$#'
identifier: parameterByRef.type
count: 1
path: ../../../src/wp-includes/class-wp-tax-query.php
-
message: '#^Parameter &\$matched_token_byte_length by\-ref type of method WP_Token_Map\:\:read_token\(\) expects int\|null, \(float\|int\) given\.$#'
identifier: parameterByRef.type
count: 1
path: ../../../src/wp-includes/class-wp-token-map.php
-
message: '#^Parameter &\$result by\-ref type of function _page_traverse_name\(\) expects array\<string\>, array given\.$#'
identifier: parameterByRef.type
count: 1
path: ../../../src/wp-includes/post.php
Loading