diff options
Diffstat (limited to 'src/main/kotlin/io')
-rw-r--r-- | src/main/kotlin/io/github/moulberry/notenoughupdates/commands/dev/NEUStatsCommand.kt | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/src/main/kotlin/io/github/moulberry/notenoughupdates/commands/dev/NEUStatsCommand.kt b/src/main/kotlin/io/github/moulberry/notenoughupdates/commands/dev/NEUStatsCommand.kt index e17e856c..d5a39cb8 100644 --- a/src/main/kotlin/io/github/moulberry/notenoughupdates/commands/dev/NEUStatsCommand.kt +++ b/src/main/kotlin/io/github/moulberry/notenoughupdates/commands/dev/NEUStatsCommand.kt @@ -188,18 +188,23 @@ class NEUStatsCommand { private fun appendRepoStats(builder: DiscordMarkdownBuilder): DiscordMarkdownBuilder { val apiData = NotEnoughUpdates.INSTANCE.config.apiData - if (apiData.repoUser == "" || apiData.repoName == "" || apiData.repoBranch == "") { - NotEnoughUpdates.INSTANCE.config.executeRunnable(23) - NotEnoughUpdates.INSTANCE.config.executeRunnable(22) - builder.append("", "") + if (apiData.repoUser.isEmpty() || apiData.repoName.isEmpty() || apiData.repoBranch.isEmpty()) { + apiData.repoUser = "NotEnoughUpdates" + apiData.repoName = "NotEnoughUpdates-REPO" + apiData.repoBranch = "master" builder.category("Reset Repository location") - builder.append("", "") } else { builder.category("Repo Stats") builder.append("Last Commit", NotEnoughUpdates.INSTANCE.manager.latestRepoCommit) - builder.append("Loaded Items", NotEnoughUpdates.INSTANCE.manager.itemInformation.size.toString()) builder.append("Repo Location", "https://github.com/${apiData.repoUser}/${apiData.repoName}/tree/${apiData.repoBranch}") } + builder.append("Loaded Items", NotEnoughUpdates.INSTANCE.manager.itemInformation.size.toString()) + if (apiData.moulberryCodesApi.isEmpty()) { + apiData.moulberryCodesApi = "moulberry.codes" + builder.category("Reset API location") + } else { + builder.append("Lowest Bin API Location", apiData.moulberryCodesApi) + } return builder } |