Skip to content

Commit

Permalink
Show an error message when pcap slices can't be opened (#3114)
Browse files Browse the repository at this point in the history
  • Loading branch information
philrz authored Jul 2, 2024
1 parent 804fe3f commit 6a90407
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions apps/zui/src/plugins/brimcap/packets/download.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,14 @@ export async function downloadPackets(root: string, pool: string, uid: string) {
const msg = JSON.parse(err)?.error || `brimcap search failed: ${err}`
window.showErrorMessage(msg)
} else {
shell.openPath(dest)
window.showSuccessMessage("Packets extracted. Opening...")
const msg = await shell.openPath(dest)
if (msg) {
window.showErrorMessage(
"Could not open extracted pcap. Is Wireshark installed?"
)
} else {
window.showSuccessMessage("Packets extracted. Opening...")
}
}
}
}
Expand Down

0 comments on commit 6a90407

Please sign in to comment.