Skip to content

Commit

Permalink
Remove unneeded code for mysql and mssql drivers
Browse files Browse the repository at this point in the history
Issue #23381
  • Loading branch information
atrol committed Sep 25, 2017
1 parent f01b08d commit 855d317
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 5 deletions.
4 changes: 1 addition & 3 deletions admin/install.php
Original file line number Diff line number Diff line change
Expand Up @@ -479,13 +479,11 @@ function print_test( $p_test_description, $p_result, $p_hard_fail = true, $p_mes
$t_warning = '';
$t_error = '';
switch( $f_db_type ) {
case 'mysql':
case 'mysqli':
if( version_compare( $t_version_info['version'], DB_MIN_VERSION_MYSQL, '<' ) ) {
$t_error = 'MySQL ' . DB_MIN_VERSION_MYSQL . ' or later is required for installation';
}
break;
case 'mssql':
case 'mssqlnative':
if( version_compare( $t_version_info['version'], DB_MIN_VERSION_MSSQL, '<' ) ) {
$t_error = 'SQL Server (' . DB_MIN_VERSION_MSSQL . ') or later is required for installation';
Expand Down Expand Up @@ -874,7 +872,7 @@ function print_test( $p_test_description, $p_result, $p_hard_fail = true, $p_mes
}

# Make sure we do the upgrades using UTF-8 if needed
if( $f_db_type === 'mysql' || $f_db_type === 'mysqli' ) {
if( $f_db_type === 'mysqli' ) {
$g_db->execute( 'SET NAMES UTF8' );
}

Expand Down
2 changes: 1 addition & 1 deletion admin/schema.php
Original file line number Diff line number Diff line change
Expand Up @@ -501,7 +501,7 @@

# Apparently mysql now has a STRICT mode, where setting a DEFAULT value on a
# blob/text is now an error, instead of being silently ignored
$g_upgrade[66] = ( isset( $f_db_type ) && ( $f_db_type == 'mysql' || $f_db_type == 'mysqli' ) )
$g_upgrade[66] = ( isset( $f_db_type ) && ( $f_db_type == 'mysqli' ) )
? array( 'AlterColumnSQL', array( db_get_table( 'custom_field' ), "
possible_values X NOTNULL" ) )
: array( 'AlterColumnSQL', array( db_get_table( 'custom_field' ), "
Expand Down
1 change: 0 additions & 1 deletion config_defaults_inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@
* RDBMS db_type PHP ext Comments
* ----- ------- ------- --------
* MySQL mysqli mysqli default
* mysql mysql PHP < 5.5.0 only
* PostgreSQL pgsql pgsql
* MS SQL Server mssqlnative sqlsrv experimental
* Oracle oci8 oci8 experimental
Expand Down

0 comments on commit 855d317

Please sign in to comment.