Skip to content

Commit b93a898

Browse files
committed
Switch from getUnchecked to get with casts in native command sender code examples
1 parent 7b2e500 commit b93a898

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

reference-code/src/main/java/createcommands/executors/NativeSender.java

+4-4
Original file line numberDiff line numberDiff line change
@@ -33,10 +33,10 @@ class NativeSender {
3333
new CommandArgument("command")
3434
)
3535
.executes((caller, args) -> {
36-
CommandSender callee = args.getUnchecked("target");
37-
Location location = args.getUnchecked("location");
38-
World world = args.getUnchecked("world");
39-
CommandResult command = args.getUnchecked("command");
36+
CommandSender callee = (CommandSender) args.get("target");
37+
Location location = (Location) args.get("location");
38+
World world = (World) args.get("world");
39+
CommandResult command = (CommandResult) args.get("command");
4040

4141
assert callee != null && location != null && world != null && command != null;
4242

0 commit comments

Comments
 (0)