Skip to content

Commit

Permalink
fix api key extraction logic
Browse files Browse the repository at this point in the history
  • Loading branch information
kMutagene committed Feb 23, 2024
1 parent 7dfab78 commit 317a082
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions scripts/publish-pending-packages.fsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@ let envVars =
.Read()

let apiKey =
if System.Environment.GetEnvironmentVariable("APIKEY") = null then
try
envVars["APIKEY"]
with e ->
failwith "APIKEY not found"
else
failwith "APIKEY not found"
if envVars.ContainsKey("APIKEY") then
envVars["APIKEY"]
else
let key = Environment.GetEnvironmentVariable("APIKEY")
if String.IsNullOrWhiteSpace(key) then failwith "APIKEY not found"
key


type AVPRClient.ValidationPackage with
static member createOfIndex (i: ValidationPackageIndex) =
Expand Down

0 comments on commit 317a082

Please sign in to comment.