[wp-trac] [WordPress Trac] #45523: PHP 7.3.0 raises E_NOTICE when compact() parameters do not refer to an existing variable
WordPress Trac
noreply at wordpress.org
Fri Dec 7 14:33:50 UTC 2018
#45523: PHP 7.3.0 raises E_NOTICE when compact() parameters do not refer to an
existing variable
----------------------------+-----------------------------
Reporter: ettoredn | Owner: (none)
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Administration | Version: 5.0
Severity: normal | Keywords:
Focuses: |
----------------------------+-----------------------------
It appears that since PHP 7.3.0 compact() raises E_NOTICE when passed
variable names are undefined.
PHP Notice: compact(): Undefined variable: post_status in wp-
admin/includes/post.php on line 1059
PHP Notice: compact(): Undefined variable: perm in wp-
admin/includes/post.php on line 1059
PHP Notice: compact(): Undefined variable: order in wp-
admin/includes/post.php on line 1059
PHP Notice: compact(): Undefined variable: orderby in wp-
admin/includes/post.php on line 1059
Steps to reproduce:
1. Install WP 5.0.0
2. set error_reporting = E_ALL
3. Log in the admin interface.
I get the feeling there a few other similar situations across the WP
codebase.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/45523>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list