Fixed /help causing NPE on Sponge

Affects issues:
- Fixed #1639
This commit is contained in:
Risto Lahtela 2020-11-05 20:20:43 +02:00
parent e13516b43c
commit 7fb9691bf8

View File

@ -103,7 +103,7 @@ public class SpongeCommand implements CommandCallable {
@Override
public Optional<Text> getShortDescription(CommandSource source) {
return Optional.of(Text.of(command.getDescription()));
return Optional.ofNullable(command.getDescription()).map(Text::of);
}
@Override