Opened 16 years ago
Closed 16 years ago
#8148 closed defect (bug) (fixed)
check return value from get_core_update() before foreach()
Reported by: | lybica | Owned by: | |
---|---|---|---|
Milestone: | 2.7 | Priority: | normal |
Severity: | normal | Version: | |
Component: | General | Keywords: | |
Focuses: | Cc: |
Description
Warning: Invalid argument supplied for foreach() in {...}/wp-admin/update-core.php on line 113
foreach() does not like the "false" returned from get_core_update() (in wp-admin/includes/update.php).
functions in update-core.php should perform return value checks like:
... if( is_array($updates) ) { foreach( $updates as $update ) { ...
(dismissed_updates(), core_upgrade_preamble() in wp-admin/update-core.php)
Note: See
TracTickets for help on using
tickets.
(In [9698]) Cast to array. fixes #8148