Skip to content
Commit a7e1a612 authored by Sergey Biryukov's avatar Sergey Biryukov
Browse files

Script Loader: Add the `$group` parameter to `WP_Dependencies::do_item()`.

Previously, the method was called with two parameters in `::do_items()`, while the method signature only included one parameter.

Technically, this was not an issue as `WP_Dependencies::do_item()` is a placeholder meant to be overwritten when extending the class. When handling scripts, `WP_Dependencies` is extended with `WP_Scripts`, and the `$group` parameter was only used in `WP_Scripts::do_item()`, which does expect a second argument.

However, officially adding the parameter to `WP_Dependencies::do_item()` signature prevents code misunderstanding and avoids a warning in PHP code inspection tools.

Props kaggdesign, soulseekah, azaozz, SergeyBiryukov.
Fixes #43627.
Built from https://develop.svn.wordpress.org/trunk@47769


git-svn-id: https://core.svn.wordpress.org/trunk@47545 1a063a9b-81f0-0310-95a4-ce76da25c4cd
parent 5a940af2
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment