[wp-trac] [WordPress Trac] #59420: Remove unused variables on the wp-includes folder.

WordPress Trac noreply at wordpress.org
Mon Feb 19 23:48:49 UTC 2024


#59420: Remove unused variables on the wp-includes folder.
--------------------------+-------------------------------
 Reporter:  upadalavipul  |       Owner:  SergeyBiryukov
     Type:  defect (bug)  |      Status:  closed
 Priority:  normal        |   Milestone:  6.4
Component:  General       |     Version:
 Severity:  normal        |  Resolution:  fixed
 Keywords:  has-patch     |     Focuses:  coding-standards
--------------------------+-------------------------------
Changes (by sabernhardt):

 * status:  reopened => closed
 * resolution:   => fixed
 * milestone:  6.5 => 6.4


Comment:

 > a new ticket on 6.5 can be opened for the ongoing work.

 #59297 already has plenty of overlap with this ticket, so that can be used
 to consider whether any additional variables should be removed.

 The change from 59420.patch and 59420.2.patch is done in [56645].

 59420.3.patch removes the `$shortcode_tags` global, but that is **used in
 several functions**, including `run_shortcode()` and `wptexturize()`.

 59420.4.patch proposes removing `$blog_id` from
 `ms_load_current_site_and_network()`, which is part of 59297.5.patch.

 59420.7.patch proposes changes in multiple unrelated files:
 - To suggest removing `$AudioChunkStreamNum` from the
 [https://github.com/JamesHeinrich/getID3/blob/c6e24a206132b64a0cb54d33c869afd76d1b01ec/getid3/module
 .audio-video.riff.php#L1547 getID3 RIFF module], please report that on the
 external library's GitHub repository.
 - The `$unapproved_ids` and `$unapproved_emails` were **already removed**
 from `WP_Comment_Query::get_comment_ids()` by [55559].
 - The `$parent_post_type` variable should not be removed from the
 `WP_REST_Revisions_Controller` class because the `__construct()` method
 uses it.

 59420.9.patch proposes removing `$hidden_inputs` from
 `the_block_editor_meta_box_post_form_hidden_fields()`, which is part of
 59297.patch.

 I'll add notes about patches 5, 6, 8 and 10 on #59297.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/59420#comment:9>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list