aboutsummaryrefslogtreecommitdiff
path: root/src/main/kotlin/io
diff options
context:
space:
mode:
authorNopoTheGamer <40329022+NopoTheGamer@users.noreply.github.com>2023-10-28 19:57:43 +1100
committerGitHub <noreply@github.com>2023-10-28 10:57:43 +0200
commitaf965ca7b13f5220d97565ee1829043d659a665f (patch)
tree64436475a867d61b1e398082b23eaa6eb1c81b5d /src/main/kotlin/io
parentf849c11c4d6fe713ef64d29e4a81c45b219c6c12 (diff)
downloadNotEnoughUpdates-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/kotlin/io')
-rw-r--r--src/main/kotlin/io/github/moulberry/notenoughupdates/commands/help/FeaturesCommand.kt2
-rw-r--r--src/main/kotlin/io/github/moulberry/notenoughupdates/commands/help/LinksCommand.kt4
-rw-r--r--src/main/kotlin/io/github/moulberry/notenoughupdates/util/PetLeveling.kt4
3 files changed, 5 insertions, 5 deletions
diff --git a/src/main/kotlin/io/github/moulberry/notenoughupdates/commands/help/FeaturesCommand.kt b/src/main/kotlin/io/github/moulberry/notenoughupdates/commands/help/FeaturesCommand.kt
index 6cc4e255..e98dd7dd 100644
--- a/src/main/kotlin/io/github/moulberry/notenoughupdates/commands/help/FeaturesCommand.kt
+++ b/src/main/kotlin/io/github/moulberry/notenoughupdates/commands/help/FeaturesCommand.kt
@@ -40,7 +40,7 @@ class FeaturesCommand {
reply("")
val url = Constants.MISC?.get("featureslist")?.asString
if (url == null) {
- Utils.showOutdatedRepoNotification()
+ Utils.showOutdatedRepoNotification("misc.json or missing featureslist")
return@thenExecute
}
diff --git a/src/main/kotlin/io/github/moulberry/notenoughupdates/commands/help/LinksCommand.kt b/src/main/kotlin/io/github/moulberry/notenoughupdates/commands/help/LinksCommand.kt
index 7a47da2b..dc995936 100644
--- a/src/main/kotlin/io/github/moulberry/notenoughupdates/commands/help/LinksCommand.kt
+++ b/src/main/kotlin/io/github/moulberry/notenoughupdates/commands/help/LinksCommand.kt
@@ -36,14 +36,14 @@ class LinksCommand {
val manager = NotEnoughUpdates.INSTANCE.manager
val updateJsonFile = manager.repoLocation.resolve("update.json")
if (!updateJsonFile.exists()) {
- Utils.showOutdatedRepoNotification()
+ Utils.showOutdatedRepoNotification("update.json")
return@thenExecute
}
try {
val updateJson = manager.getJsonFromFile(updateJsonFile)
NotEnoughUpdates.INSTANCE.displayLinks(updateJson, 0)
} catch (_: Exception) {
- Utils.showOutdatedRepoNotification()
+ Utils.showOutdatedRepoNotification("some error with update.json")
}
}
}.withHelp("Display links for Moulberry and NEU")
diff --git a/src/main/kotlin/io/github/moulberry/notenoughupdates/util/PetLeveling.kt b/src/main/kotlin/io/github/moulberry/notenoughupdates/util/PetLeveling.kt
index 99066e52..9f809798 100644
--- a/src/main/kotlin/io/github/moulberry/notenoughupdates/util/PetLeveling.kt
+++ b/src/main/kotlin/io/github/moulberry/notenoughupdates/util/PetLeveling.kt
@@ -20,10 +20,10 @@
package io.github.moulberry.notenoughupdates.util
import com.google.gson.JsonObject
+import io.github.moulberry.notenoughupdates.autosubscribe.NEUAutoSubscribe
import io.github.moulberry.notenoughupdates.events.RepositoryReloadEvent
import io.github.moulberry.notenoughupdates.miscfeatures.PetInfoOverlay.Rarity
import net.minecraftforge.fml.common.eventhandler.SubscribeEvent
-import io.github.moulberry.notenoughupdates.autosubscribe.NEUAutoSubscribe
@NEUAutoSubscribe
object PetLeveling {
@@ -94,7 +94,7 @@ object PetLeveling {
}
val stubExpLadder by lazy {
- Utils.showOutdatedRepoNotification()
+ Utils.showOutdatedRepoNotification("pets.json")
ExpLadder(listOf(1, 1))
}