Skip to content

Commit

Permalink
small code improv if we ever decide on strict comparisons
Browse files Browse the repository at this point in the history
  • Loading branch information
liedekef committed Jan 5, 2023
1 parent 4a05378 commit 488c912
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions eme-functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -2681,11 +2681,11 @@ function eme_table_exists( $table_name ) {
}

function eme_maybe_drop_column( $table_name, $column_name ) {
global $wpdb,$eme_db_prefix;
global $wpdb,$eme_db_prefix;
if ( eme_column_exists( $table_name, $column_name ) ) {
$wpdb->query( "ALTER TABLE $table_name DROP COLUMN $column_name;" );
}
return true;
return true;
}

function eme_drop_table( $table ) {
Expand All @@ -2704,7 +2704,7 @@ function eme_get_total( $multistring ) {
if ( eme_is_multi( $multistring ) ) {
return array_sum( eme_convert_multi2array( $multistring ) );
} else {
return $multistring;
return $multistring+0; // convert to a number (type is float if string is a float, otherwise it is int)
}
}

Expand Down

0 comments on commit 488c912

Please sign in to comment.