Opened 9 years ago
Closed 9 years ago
#28872 closed defect (bug) (fixed)
Remove unused $check_urls and $description variables from wp-admin/includes/dashboard.php
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 4.0 | Priority: | low |
Severity: | normal | Version: | 3.9 |
Component: | Administration | Keywords: | has-patch commit |
Focuses: | Cc: |
Description
Variable $check_urls
is passed by function param and the redefined version of it on line 833 isn't used.
URLs passed to the callback are from the function param $args = array_slice( func_get_args(), 2 );
The $description
variable on line 1096 is not used afterwards.
Attachments (3)
Change History (11)
#2
@
9 years ago
- Keywords needs-patch added
- Milestone changed from Awaiting Review to 4.0
- Priority changed from normal to low
Variable
$check_urls
So func_get_args()
ignores empty arguments and returns a copy of the passed arguments, means you can't override it. Has it ever worked?
#4
@
9 years ago
$func = function ( $one, $two, $three = array() ) { $three = 3; print_r( func_get_args() ); }; $func( 1, 2 );
Results in:
Array ( [0] => 1 [1] => 2 )
This never worked - that dashboard code is beyond bizarre
#6
@
9 years ago
@ocean90 what's wrong with 28872.2.diff ?
Isn't it a bit cleaner without array slicing and shifting? If I'm missing something, I apologize.
Note: See
TracTickets for help on using
tickets.
In 29130: