@@ -28,7 +28,7 @@ export async function uploadAllAvailableDebugArtifacts(
2828 config : Config ,
2929 logger : Logger ,
3030) {
31- let filesToUpload : string [ ] = [ ] ;
31+ const filesToUpload : string [ ] = [ ] ;
3232
3333 const analyzeActionOutputDir = process . env [ EnvVar . SARIF_RESULTS_OUTPUT_DIR ] ;
3434 for ( const lang of config . languages ) {
@@ -46,15 +46,15 @@ export async function uploadAllAvailableDebugArtifacts(
4646 `${ lang } .sarif` ,
4747 ) ;
4848 fs . renameSync ( sarifFile , sarifInDbLocation ) ;
49- filesToUpload = filesToUpload . concat ( sarifInDbLocation ) ;
49+ filesToUpload . push ( sarifInDbLocation ) ;
5050 }
5151 }
5252
5353 // Add any log files
5454 const databaseDirectory = getCodeQLDatabasePath ( config , lang ) ;
5555 const logsDirectory = path . resolve ( databaseDirectory , "log" ) ;
5656 if ( doesDirectoryExist ( logsDirectory ) ) {
57- filesToUpload = filesToUpload . concat ( listFolder ( logsDirectory ) ) ;
57+ filesToUpload . push ( ... listFolder ( logsDirectory ) ) ;
5858 }
5959
6060 // Multilanguage tracing: there are additional logs in the root of the cluster
@@ -63,9 +63,7 @@ export async function uploadAllAvailableDebugArtifacts(
6363 "log" ,
6464 ) ;
6565 if ( doesDirectoryExist ( multiLanguageTracingLogsDirectory ) ) {
66- filesToUpload = filesToUpload . concat (
67- listFolder ( multiLanguageTracingLogsDirectory ) ,
68- ) ;
66+ filesToUpload . push ( ...listFolder ( multiLanguageTracingLogsDirectory ) ) ;
6967 }
7068
7169 // Add database bundle
@@ -75,7 +73,7 @@ export async function uploadAllAvailableDebugArtifacts(
7573 } else {
7674 databaseBundlePath = await createDatabaseBundleCli ( config , lang ) ;
7775 }
78- filesToUpload = filesToUpload . concat ( databaseBundlePath ) ;
76+ filesToUpload . push ( databaseBundlePath ) ;
7977 }
8078
8179 await uploadDebugArtifacts (
0 commit comments