Making WordPress.org


Ignore:
Timestamp:
12/18/2024 06:12:50 AM (20 months ago)
Author:
dd32
Message:

Plugin Directory: SVN: Handle the case where there's null $output to avoid PHP Warnings.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/tools/class-svn.php

    r13729 r14312  
    526526         */
    527527        protected static function parse_svn_errors( $output ) {
    528                 if ( preg_match_all( '!^svn: (?P<warning>warning:)?\s*(?<error_code>[EW]\d+):\s*(?P<error_message>.+)$!im', $output, $messages, PREG_SET_ORDER ) ) {
     528                if ( preg_match_all( '!^svn: (?P<warning>warning:)?\s*(?<error_code>[EW]\d+):\s*(?P<error_message>.+)$!im', $output ?? '', $messages, PREG_SET_ORDER ) ) {
    529529
    530530                        // We only want the string keys - strip out the numeric keys
Note: See TracChangeset for help on using the changeset viewer.