From b1219df74d30a84a643d86458c7f9635305f4202 Mon Sep 17 00:00:00 2001 From: SpacEagle17 <46494907+SpacEagle17@users.noreply.github.com> Date: Thu, 9 Jul 2026 19:23:49 +0200 Subject: [PATCH] Use the user agent also while downloading smh, now Modrinth can actually track it. --- gradle.properties | 2 +- src/main/java/net/hypercubemc/iris_installer/Downloader.java | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/gradle.properties b/gradle.properties index 24fa05e..2e02fa9 100644 --- a/gradle.properties +++ b/gradle.properties @@ -2,7 +2,7 @@ org.gradle.jvmargs=-Xmx1G # Version and packaging info -version=1.3.0 +version=1.3.1 maven_group= archives_base_name=Complementary-Installer diff --git a/src/main/java/net/hypercubemc/iris_installer/Downloader.java b/src/main/java/net/hypercubemc/iris_installer/Downloader.java index 2709990..4c591d0 100644 --- a/src/main/java/net/hypercubemc/iris_installer/Downloader.java +++ b/src/main/java/net/hypercubemc/iris_installer/Downloader.java @@ -29,6 +29,7 @@ protected Void doInBackground() throws Exception { URL url = new URL(this.url); HttpsURLConnection connection = (HttpsURLConnection) url .openConnection(); + connection.setRequestProperty("User-Agent", "Complementary-Installer"); long filesize = connection.getContentLengthLong(); if (filesize == -1) {