From 9ff67cb2d239dc1b22dd32e6fb397baf426fbd81 Mon Sep 17 00:00:00 2001
From: Ryan Ghadimi <114221941+GhadimiR@users.noreply.github.com>
Date: Wed, 12 Mar 2025 16:17:52 +0000
Subject: [PATCH] Break the thing, also log the expected digest

---
 src/download-artifact.ts | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/download-artifact.ts b/src/download-artifact.ts
index 1dfef71..dda08c6 100644
--- a/src/download-artifact.ts
+++ b/src/download-artifact.ts
@@ -106,7 +106,7 @@ async function run(): Promise<void> {
     core.info(`Preparing to download the following artifacts:`)
     artifacts.forEach(artifact => {
       core.info(
-        `- ${artifact.name} (ID: ${artifact.id}, Size: ${artifact.size})`
+        `- ${artifact.name} (ID: ${artifact.id}, Size: ${artifact.size}, Expected Digest: ${artifact.digest})`
       )
     })
   }
@@ -132,7 +132,7 @@ async function run(): Promise<void> {
       const outcome = results[i]
       const artifactName = chunk[i].name
 
-      if (outcome.digestMismatch) {
+      if (!outcome.digestMismatch) {
         core.warning(
           `Artifact '${artifactName}' digest validation failed. Please verify the integrity of the artifact.`
         )