Skip to content
This repository has been archived by the owner on Aug 2, 2023. It is now read-only.

Commit

Permalink
console: fix failure when cloudfront identities is undefined
Browse files Browse the repository at this point in the history
  • Loading branch information
robbytaylor committed Oct 7, 2019
1 parent 2d88fd5 commit cd5b236
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/formatters/console.ts
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,10 @@ export default class Console implements S3Audit.Types.Formatter {
task.skip(error.message)
})
.then((identities: Array<string>) => {
if (identities === undefined) {
return
}

if (identities.length === 0) {
task.title = 'Bucket is not associated with any CloudFront distributions'

Expand Down

0 comments on commit cd5b236

Please sign in to comment.