Skip to content

Commit

Permalink
Install: only generate message when step is SQL
Browse files Browse the repository at this point in the history
When processing a failed upgrade step, the installer builds a message
to provide info to the user, including all the executed SQL statements.

This is not necessary when processing a non-SQL step (UpdateFunction)
as this just duplicates the function name which is already displayed
in the 1st column.

Fixes #20644
  • Loading branch information
dregad committed Feb 28, 2016
1 parent 07c78be commit 5b6f269
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions admin/install.php
Expand Up @@ -1012,9 +1012,11 @@ function print_test( $p_test_description, $p_result, $p_hard_fail = true, $p_mes
config_set( 'database_version', $i );
} else {
$t_all_sql = '';
foreach ( $t_sqlarray as $t_single_sql ) {
if( !empty( $t_single_sql ) ) {
$t_all_sql .= $t_single_sql . '<br />';
if( $t_sql ) {
foreach( $t_sqlarray as $t_single_sql ) {
if( !empty( $t_single_sql ) ) {
$t_all_sql .= $t_single_sql . '<br />';
}
}
}
print_test_result( BAD, true, $t_all_sql . $g_db->ErrorMsg() );
Expand Down

0 comments on commit 5b6f269

Please sign in to comment.