From c181c7825ba70b47e038cd66fc7c45dab538d28d Mon Sep 17 00:00:00 2001 From: Glavo Date: Sat, 21 Mar 2026 21:31:11 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BD=93=20CurseForge=20API=20Key=20=E7=BC=BA?= =?UTF-8?q?=E5=A4=B1=E6=97=B6=E9=9A=90=E8=97=8F=E4=B8=8B=E8=BD=BD=E6=BA=90?= =?UTF-8?q?=E5=88=87=E6=8D=A2=E9=80=89=E9=A1=B9=20(#5802)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../hmcl/ui/versions/HMCLLocalizedDownloadListPage.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/HMCL/src/main/java/org/jackhuang/hmcl/ui/versions/HMCLLocalizedDownloadListPage.java b/HMCL/src/main/java/org/jackhuang/hmcl/ui/versions/HMCLLocalizedDownloadListPage.java index 2ef0682931..8b77f45617 100644 --- a/HMCL/src/main/java/org/jackhuang/hmcl/ui/versions/HMCLLocalizedDownloadListPage.java +++ b/HMCL/src/main/java/org/jackhuang/hmcl/ui/versions/HMCLLocalizedDownloadListPage.java @@ -61,7 +61,12 @@ public final class HMCLLocalizedDownloadListPage extends DownloadListPage { repository = new Repository(type, curseForge, modrinth); supportChinese.set(true); - downloadSources.get().setAll("mods.modrinth", "mods.curseforge"); + + downloadSources.setAll("mods.modrinth"); + if (CurseForgeRemoteModRepository.isAvailable()) { + downloadSources.add("mods.curseforge"); + } + if (modrinth != null) { downloadSource.set("mods.modrinth"); } else if (curseForge != null) {