diff options
author | hannibal2 <24389977+hannibal002@users.noreply.github.com> | 2024-08-24 15:02:10 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-08-24 15:02:10 +0200 |
commit | aa48336b2f4fa8c5bdc1fbabd6e144c475013198 (patch) | |
tree | b8427810a0493c07648a84ce14abaad70b752d3c /src/main/java/at/hannibal2/skyhanni/tweaker | |
parent | 4b21b3f78f11906c5112ba3bed94aeffa129569a (diff) | |
download | skyhanni-aa48336b2f4fa8c5bdc1fbabd6e144c475013198.tar.gz skyhanni-aa48336b2f4fa8c5bdc1fbabd6e144c475013198.tar.bz2 skyhanni-aa48336b2f4fa8c5bdc1fbabd6e144c475013198.zip |
Backend: Version to download source checker (#2400)
Co-authored-by: hannibal2 <24389977+hannibal00212@users.noreply.github.com>
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/tweaker')
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/tweaker/DownloadSourceChecker.java | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/tweaker/DownloadSourceChecker.java b/src/main/java/at/hannibal2/skyhanni/tweaker/DownloadSourceChecker.java index 3f4755be3..5fb46592e 100644 --- a/src/main/java/at/hannibal2/skyhanni/tweaker/DownloadSourceChecker.java +++ b/src/main/java/at/hannibal2/skyhanni/tweaker/DownloadSourceChecker.java @@ -1,5 +1,7 @@ package at.hannibal2.skyhanni.tweaker; +import at.hannibal2.skyhanni.SkyHanniMod; + import javax.swing.JFrame; import javax.swing.JOptionPane; import javax.swing.JPanel; @@ -94,10 +96,11 @@ public class DownloadSourceChecker { } )); + String version = SkyHanniMod.Companion.getVersion(); JOptionPane.showOptionDialog( frame, String.format(String.join("\n", SECURITY_POPUP), uriToSimpleString(host)), - "SkyHanni Security Error", + "SkyHanni " + version + " Security Error", JOptionPane.DEFAULT_OPTION, JOptionPane.ERROR_MESSAGE, null, @@ -135,7 +138,7 @@ public class DownloadSourceChecker { private static URI getHost(File file) throws Exception { final File adsFile = new File(file.getAbsolutePath() + ":Zone.Identifier:$DATA"); String host = null; - try(BufferedReader reader = new BufferedReader(new FileReader(adsFile))) { + try (BufferedReader reader = new BufferedReader(new FileReader(adsFile))) { String line = reader.readLine(); while (line != null) { if (line.startsWith("HostUrl=")) { |