Merge pull request #27987 from woocommerce/php8/fix-required-parameters-after-optional-take-2
[PHP 8] Convert optional-before-required parameters into required parameters (take 2)
This commit is contained in:
commit
0a81188e42
|
@ -387,7 +387,7 @@ class WC_Admin_Taxonomies {
|
|||
* @param object $term Term object.
|
||||
* @return array
|
||||
*/
|
||||
public function product_cat_row_actions( $actions = array(), $term ) {
|
||||
public function product_cat_row_actions( $actions, $term ) {
|
||||
$default_category_id = absint( get_option( 'default_product_cat', 0 ) );
|
||||
|
||||
if ( $default_category_id !== $term->term_id && current_user_can( 'edit_term', $term->term_id ) ) {
|
||||
|
|
|
@ -93,7 +93,7 @@ class WC_Product_Cat_Dropdown_Walker extends Walker {
|
|||
* @param string $output Passed by reference. Used to append additional content.
|
||||
* @return null Null on failure with no changes to parameters.
|
||||
*/
|
||||
public function display_element( $element, &$children_elements, $max_depth, $depth = 0, $args, &$output ) {
|
||||
public function display_element( $element, &$children_elements, $max_depth, $depth, $args, &$output ) {
|
||||
if ( ! $element || ( 0 === $element->count && ! empty( $args[0]['hide_empty'] ) ) ) {
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -144,7 +144,7 @@ class WC_Product_Cat_List_Walker extends Walker {
|
|||
* @param string $output Passed by reference. Used to append additional content.
|
||||
* @return null Null on failure with no changes to parameters.
|
||||
*/
|
||||
public function display_element( $element, &$children_elements, $max_depth, $depth = 0, $args, &$output ) {
|
||||
public function display_element( $element, &$children_elements, $max_depth, $depth, $args, &$output ) {
|
||||
if ( ! $element || ( 0 === $element->count && ! empty( $args[0]['hide_empty'] ) ) ) {
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue