From d9b10b79c074bed7a2a138d15db787d1eeda6101 Mon Sep 17 00:00:00 2001 From: Wes Haggard Date: Wed, 15 Oct 2025 15:04:40 -0700 Subject: [PATCH] Reorder error and warning log line processing --- eng/common/scripts/logging.ps1 | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/eng/common/scripts/logging.ps1 b/eng/common/scripts/logging.ps1 index c27bfee712be..4700a5716453 100644 --- a/eng/common/scripts/logging.ps1 +++ b/eng/common/scripts/logging.ps1 @@ -114,12 +114,12 @@ function LogJobFailure() { function ProcessMsBuildLogLine($line) { if (Test-SupportsDevOpsLogging) { - if ($line -like "*: warning*") { - return ("##vso[task.LogIssue type=warning;]$line" -replace "`n", "%0D%0A") - } - elseif ($line -like "*: error*") { + if ($line -like "*: error*") { return ("##vso[task.LogIssue type=error;]$line" -replace "`n", "%0D%0A") } + elseif ($line -like "*: warning*") { + return ("##vso[task.LogIssue type=warning;]$line" -replace "`n", "%0D%0A") + } } return $line }