Skip to content

Commit bea936a

Browse files
committed
Combine DROP statements
1 parent 1caeac9 commit bea936a

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

src/DB_Command_SQLite.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -389,9 +389,8 @@ protected function sqlite_export( $file, $assoc_args ) {
389389
}
390390

391391
if ( ! empty( $drop_statements ) ) {
392-
$args = array_merge( array( 'sqlite3', $temp_db ), $drop_statements );
393-
$placeholders = array_fill( 0, count( $args ), '%s' );
394-
$command = Utils\esc_cmd( implode( ' ', $placeholders ), ...$args );
392+
$sql = implode( ' ', $drop_statements );
393+
$command = Utils\esc_cmd( 'sqlite3 %s %s', $temp_db, $sql );
395394

396395
WP_CLI::debug( "Running shell command: {$command}", 'db' );
397396

0 commit comments

Comments
 (0)