From d4299234816d798ea0c14ac40a514cf53593a7aa Mon Sep 17 00:00:00 2001 From: csmig <33138761+csmig@users.noreply.github.com> Date: Tue, 20 Dec 2022 09:25:40 -0500 Subject: [PATCH] fix: case insensitive matching (#41) --- lib/cargo.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/cargo.js b/lib/cargo.js index f44d749..ad977ac 100644 --- a/lib/cargo.js +++ b/lib/cargo.js @@ -53,8 +53,8 @@ class TaskObject { const matchedByCklHostname = this.mappedCklHostnames.get(target.metadata.cklHostName.toLowerCase()) if (!matchedByCklHostname) return null const matchedByAllCklMetadata = matchedByCklHostname.find( - asset => asset.metadata.cklWebDbInstance === target.metadata.cklWebDbInstance - && asset.metadata.cklWebDbSite === target.metadata.cklWebDbSite) + asset => asset.metadata.cklWebDbInstance?.toLowerCase() === target.metadata.cklWebDbInstance?.toLowerCase() + && asset.metadata.cklWebDbSite?.toLowerCase() === target.metadata.cklWebDbSite?.toLowerCase()) if (!matchedByAllCklMetadata) return null return matchedByAllCklMetadata }