From e2d12a94d690179bc6f55313847d8d6439c24067 Mon Sep 17 00:00:00 2001 From: itsmeow <mods.itsmeow@gmail.com> Date: Fri, 6 Mar 2020 13:30:52 -0500 Subject: [PATCH] I'm confused --- .github/workflows/test.yml | 2 +- curseforge-upload.js | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 3066c80..77fa844 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,5 +1,5 @@ name: Test - +# on: push: paths: diff --git a/curseforge-upload.js b/curseforge-upload.js index 17f68e2..c58cb17 100644 --- a/curseforge-upload.js +++ b/curseforge-upload.js @@ -44,6 +44,7 @@ async function getGameVersions(token, endpoint) { const versionTypeData = Object.values(gameVersionNames).filter((v,i,a) => v != "blank").length > 0 ? JSON.parse(await requestPromise(optionsTypes)) : []; const filteredVersions = versionData.filter(function(value, index, array) { + let typeId = gameVersionNames.hasOwnProperty(value.name) ? gameVersionNames[value.name] : (gameVersionNames.hasOwnProperty(value.slug) ? gameVersionNames[value.slug] : ""); if(typeId != null && typeId != "blank" && typeId != "") { if(isID(typeId)) {