From 708224f5ff7cd18fa4f248c9027d2a213468f97d Mon Sep 17 00:00:00 2001 From: Martin Sulikowski Date: Sun, 12 Jan 2025 14:09:38 +0100 Subject: [PATCH] Update eternalcore-core/src/main/java/com/eternalcode/core/feature/warp/data/WarpDataDataRepositoryImpl.java Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> --- .../core/feature/warp/data/WarpDataDataRepositoryImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eternalcore-core/src/main/java/com/eternalcode/core/feature/warp/data/WarpDataDataRepositoryImpl.java b/eternalcore-core/src/main/java/com/eternalcode/core/feature/warp/data/WarpDataDataRepositoryImpl.java index 1527a3ab8..153a446ff 100644 --- a/eternalcore-core/src/main/java/com/eternalcode/core/feature/warp/data/WarpDataDataRepositoryImpl.java +++ b/eternalcore-core/src/main/java/com/eternalcode/core/feature/warp/data/WarpDataDataRepositoryImpl.java @@ -95,7 +95,7 @@ private void edit(Consumer> editor) { @Override public CompletableFuture> getWarp(String name) { - return CompletableFuture.completedFuture(Optional.of(this.warpDataConfig.warps.get(name)) + return CompletableFuture.completedFuture(Optional.ofNullable(this.warpDataConfig.warps.get(name)) .map(warpDataConfigRepresenter -> new WarpImpl(name, warpDataConfigRepresenter.position, warpDataConfigRepresenter.permissions))); }