@@ -951,7 +951,6 @@ public function download_wp( $subdir = '' ) {
951951 if ( 'sqlite ' === self ::$ db_type ) {
952952 self ::copy_dir ( self ::$ sqlite_cache_dir , $ dest_dir . '/wp-content/plugins ' );
953953 self ::configure_sqlite ( $ dest_dir );
954-
955954 }
956955 }
957956
@@ -963,6 +962,11 @@ public function create_config( $subdir = '', $extra_php = false ) {
963962
964963 $ params ['skip-salts ' ] = true ;
965964
965+ // Do not check database connection if running SQLite as the check would fail.
966+ if ( 'sqlite ' === self ::$ db_type ) {
967+ $ params ['skip-check ' ] = true ;
968+ }
969+
966970 if ( false !== $ extra_php ) {
967971 $ params ['extra-php ' ] = $ extra_php ;
968972 }
@@ -1012,10 +1016,11 @@ public function install_wp( $subdir = '' ) {
10121016 'skip-email ' => true ,
10131017 ];
10141018
1019+ $ run_dir = '' !== $ subdir ? ( $ this ->variables ['RUN_DIR ' ] . "/ $ subdir " ) : $ this ->variables ['RUN_DIR ' ];
10151020 $ install_cache_path = '' ;
1021+
10161022 if ( self ::$ install_cache_dir ) {
10171023 $ install_cache_path = self ::$ install_cache_dir . '/install_ ' . md5 ( implode ( ': ' , $ install_args ) . ':subdir= ' . $ subdir );
1018- $ run_dir = '' !== $ subdir ? ( $ this ->variables ['RUN_DIR ' ] . "/ $ subdir " ) : $ this ->variables ['RUN_DIR ' ];
10191024 }
10201025
10211026 if ( $ install_cache_path && file_exists ( $ install_cache_path ) ) {
@@ -1029,8 +1034,10 @@ public function install_wp( $subdir = '' ) {
10291034 }
10301035 } else {
10311036 $ this ->proc ( 'wp core install ' , $ install_args , $ subdir )->run_check ();
1037+
10321038 if ( $ install_cache_path ) {
10331039 mkdir ( $ install_cache_path );
1040+
10341041 self ::dir_diff_copy ( $ run_dir , self ::$ cache_dir , $ install_cache_path );
10351042
10361043 if ( 'mysql ' === self ::$ db_type ) {
0 commit comments