🎨 Change (improve) command context semantics
This commit is contained in:
parent
ee59066733
commit
9d47a7c82d
8 changed files with 33 additions and 30 deletions
|
|
@ -95,7 +95,7 @@ public class JLineCommandManager extends CommandManager<JLineCommandSender> impl
|
|||
return ArgumentParseResult.success(
|
||||
stringBuilder.toString());
|
||||
})).build())
|
||||
.handler(commandContext -> commandContext.get("string")
|
||||
.handler(commandContext -> commandContext.getOptional("string")
|
||||
.ifPresent(
|
||||
System.out::println))
|
||||
.build())
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue