Skip to content

Commit

Permalink
minor tweak
Browse files Browse the repository at this point in the history
  • Loading branch information
aristath committed Oct 18, 2022
1 parent 4d7a07d commit e6e9615
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -350,7 +350,8 @@ private function handle_modify_column( $queries ) {
$create_query = array_shift( $index_queries );
if ( stripos( $create_query, $tokenized_query['column_name'] ) === false ) {
return 'SELECT 1=1';
} elseif ( preg_match( "/{$tokenized_query['column_name']}\\s*{$column_def}\\s*[,)]/i", $create_query ) ) {
}
if ( preg_match( "/{$tokenized_query['column_name']}\\s*{$column_def}\\s*[,)]/i", $create_query ) ) {
return 'SELECT 1=1';
}
$create_query = preg_replace( "/{$tokenized_query['table_name']}/i", $temp_table, $create_query );
Expand Down

0 comments on commit e6e9615

Please sign in to comment.