Correct unsafe future joining

This commit is contained in:
William278 committed 2022-09-07 22:36:06 +03:00
1 parent adac00ea47
commit 950a51c140
14 files changed
+42 -42

No files matched your search

@@ -44,7 +44,7 @@ public class EditHomeCommand extends CommandBase implements TabCompletable {
return;
}
}
plugin.getDatabase().getHome(userData.user(), homeIdentifier.homeName()).thenAccept(optionalHome -> {
plugin.getDatabase().getHome(userData.user(), homeIdentifier.homeName()).thenAcceptAsync(optionalHome -> {
if (optionalHome.isEmpty()) {
plugin.getLocales().getLocale("error_home_invalid_other",
homeIdentifier.ownerName(), homeIdentifier.homeName())