Making WordPress.org

Changeset 10787

Timestamp:
03/05/2021 04:18:19 AM (3 years ago)
Author:
dd32
Message:

Theme Directory: reformat the layout of the failed command errors, for better handling in the error logging.

Follow up to [10786].

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/theme-directory/class-wporg-themes-upload.php

    r10786 r10787  
    12811281        }
    12821282
     1283
     1284
     1285
    12831286        if ( $return_var > 0 ) {
    1284             trigger_error( "Command failed, `{$command}` return value: {$return_var} STDOUT: ```{$stdout}``` STDERR: ```{$stderr}```", E_USER_WARNING );
     1287            trigger_error(
     1288                "Command failed, `{$command}`\n" .
     1289                    "Return Value: {$return_var}\n" .
     1290                    "STDOUT: ```{$stdout}```\n" .
     1291                    "STDERR: ```{$stderr}```",
     1292                E_USER_WARNING
     1293            );
    12851294        } elseif ( $stderr ) {
    1286             trigger_error( "Command produced errors, `{$command}` return value: {$return_var} STDOUT: ```{$stdout}``` STDERR: ```{$stderr}```", E_USER_NOTICE );
     1295            trigger_error(
     1296                "Command produced errors, `{$command}`\n" .
     1297                    "Return Value: {$return_var}\n" .
     1298                    "STDOUT: ```{$stdout}```\n" .
     1299                    "STDERR: ```{$stderr}```",
     1300                E_USER_NOTICE
     1301            );
    12871302        }
    12881303
Note: See TracChangeset for help on using the changeset viewer.