Skip to content
This repository was archived by the owner on Jun 19, 2021. It is now read-only.

Commit 60089a2

Browse files
committed
Hot fix
1 parent 9c34bf8 commit 60089a2

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

src/main/java/org/yatopiamc/bot/commands/CommandMappingSpecific.java

+10-2
Original file line numberDiff line numberDiff line change
@@ -104,13 +104,21 @@ private void handle(
104104
(baseType == BaseMappingType.SPIGOT ? bot.spigotParser : bot.yarnParser)
105105
.parseMapping(mappingType, version, mapping);
106106
if (mappings.isEmpty()) {
107-
channel.sendMessage("No information found for: " + mapping).queue();
107+
if (mapping.contains("@")) {
108+
channel.sendMessage("No information found.").queue();
109+
} else {
110+
channel.sendMessage("No information found for: " + mapping).queue();
111+
}
108112
return;
109113
}
110114
MappingPaginator paginator = new MappingPaginator(mappings);
111115
List<Mapping> paged = paginator.getPage(page);
112116
if (paged.isEmpty()) {
113-
channel.sendMessage("Invalid page " + page).queue();
117+
if (mapping.contains("@")) {
118+
channel.sendMessage("Invalid page.").queue();
119+
} else {
120+
channel.sendMessage("Invalid page " + page).queue();
121+
}
114122
return;
115123
}
116124
StringBuilder messageBuilder = new StringBuilder();

0 commit comments

Comments
 (0)