Skip to content

Commit

Permalink
chore: improve response logging for debugging purposes
Browse files Browse the repository at this point in the history
  • Loading branch information
ChecksumDev committed Jul 18, 2024
1 parent bee5e8f commit 7a7854b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,14 @@ async function downloadFile(
}
})

core.info(`Response status: ${response.status}`)
core.info(`Response headers: ${JSON.stringify([...response.headers])}`)

if (!response.ok) {
core.error(`Failed to download file: ${response.statusText}`)
throw new Error(`Failed to download file: ${response.statusText}`)
}

core.info(`Response status: ${response.status}`)
core.info(`Response headers: ${JSON.stringify([...response.headers])}`)

await fs.mkdir(dirname(outputPath), { recursive: true })
core.info(`Directory created for output path: ${dirname(outputPath)}`)

Expand Down

0 comments on commit 7a7854b

Please sign in to comment.