diff options
| author | NopoTheGamer <40329022+NopoTheGamer@users.noreply.github.com> | 2023-10-28 19:57:43 +1100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-10-28 10:57:43 +0200 |
| commit | af965ca7b13f5220d97565ee1829043d659a665f (patch) | |
| tree | 64436475a867d61b1e398082b23eaa6eb1c81b5d /src/main/java/io/github/moulberry/notenoughupdates/util/Utils.java | |
| parent | f849c11c4d6fe713ef64d29e4a81c45b219c6c12 (diff) | |
| download | notenoughupdates-af965ca7b13f5220d97565ee1829043d659a665f.tar.gz notenoughupdates-af965ca7b13f5220d97565ee1829043d659a665f.tar.bz2 notenoughupdates-af965ca7b13f5220d97565ee1829043d659a665f.zip | |
Added logging to repo error popup (#904)
Made the repo error log what file is missing
Diffstat (limited to 'src/main/java/io/github/moulberry/notenoughupdates/util/Utils.java')
| -rw-r--r-- | src/main/java/io/github/moulberry/notenoughupdates/util/Utils.java | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/util/Utils.java b/src/main/java/io/github/moulberry/notenoughupdates/util/Utils.java index 47549fec..f879631e 100644 --- a/src/main/java/io/github/moulberry/notenoughupdates/util/Utils.java +++ b/src/main/java/io/github/moulberry/notenoughupdates/util/Utils.java @@ -2234,7 +2234,8 @@ public class Utils { return stringBuilder.toString(); } - public static void showOutdatedRepoNotification() { + private static long lastError = -1; + public static void showOutdatedRepoNotification(String missingFile) { if (NotEnoughUpdates.INSTANCE.config.notifications.outdatedRepo) { NotificationHandler.displayNotification(Lists.newArrayList( EnumChatFormatting.RED + EnumChatFormatting.BOLD.toString() + "Missing repo data", @@ -2253,6 +2254,10 @@ public class Utils { false, true ); } + if (System.currentTimeMillis() - lastError > 1000) { + System.err.println("[NEU] Repo issue: " + missingFile); + lastError = System.currentTimeMillis(); + } } /** |
