From c6ea937fb44651565af76be9d4e24160bfc63d8b Mon Sep 17 00:00:00 2001 From: derekenjibowden <57647615+derekenjibowden@users.noreply.github.com> Date: Tue, 12 Nov 2019 00:26:33 -0600 Subject: [PATCH] Fix show details bug (#647) check prereqs with -showdetails was executing the prereq command instead of showing the details --- .../Invoke-AtomicRedTeam/Public/Invoke-AtomicTest.ps1 | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/execution-frameworks/Invoke-AtomicRedTeam/Invoke-AtomicRedTeam/Public/Invoke-AtomicTest.ps1 b/execution-frameworks/Invoke-AtomicRedTeam/Invoke-AtomicRedTeam/Public/Invoke-AtomicTest.ps1 index afd1c5d0..d05b1b3f 100644 --- a/execution-frameworks/Invoke-AtomicRedTeam/Invoke-AtomicRedTeam/Public/Invoke-AtomicTest.ps1 +++ b/execution-frameworks/Invoke-AtomicRedTeam/Invoke-AtomicRedTeam/Public/Invoke-AtomicTest.ps1 @@ -231,8 +231,10 @@ function Invoke-AtomicTest { Write-Debug -Message 'Getting executor and build command script' - if ($ShowDetails -and ($null -ne $finalCommand)) { - Write-Information -MessageData $finalCommand -Tags 'Command' + if ($ShowDetails) { + if ($null -ne $finalCommand){ + Write-Information -MessageData $finalCommand -Tags 'Command' + } } else { $startTime = get-date