WordPress.org

Make WordPress Core


Ignore:
Timestamp:
12/14/2018 05:12:12 AM (2 years ago)
Author:
desrosj
Message:

PHP7.3 compatibility: Fix compact throwing notices.

In PHP 7.3, the compact() function has been changed to issue an E_NOTICE level error if a passed string refers to an unset variable. In previous versions of PHP, this notice was silently skipped. The full RFC can be viewed here: https://wiki.php.net/rfc/compact.

Props jorbin, desrosj.

Merges [43819] and [43832] to trunk.

Fixes #44416.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/src/wp-includes/comment.php

    r43982 r44166  
    30833083function wp_handle_comment_submission( $comment_data ) {
    30843084
    3085     $comment_post_ID = $comment_parent = 0;
     3085    $comment_post_ID = $comment_parent = $user_ID = 0;
    30863086    $comment_author  = $comment_author_email = $comment_author_url = $comment_content = null;
    30873087
Note: See TracChangeset for help on using the changeset viewer.