From 3a3a2e223f2a10c2e55e3c7d51785c9c1be269bb Mon Sep 17 00:00:00 2001 From: Liam Date: Wed, 10 Apr 2024 08:21:52 +0100 Subject: [PATCH] don't return the cache id for servers --- .../cc.fascinated/model/cache/CachedMinecraftServer.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/main/java/cc.fascinated/model/cache/CachedMinecraftServer.java b/src/main/java/cc.fascinated/model/cache/CachedMinecraftServer.java index 000497c..1b4572e 100644 --- a/src/main/java/cc.fascinated/model/cache/CachedMinecraftServer.java +++ b/src/main/java/cc.fascinated/model/cache/CachedMinecraftServer.java @@ -1,6 +1,7 @@ package cc.fascinated.model.cache; import cc.fascinated.model.server.MinecraftServer; +import com.fasterxml.jackson.annotation.JsonIgnore; import lombok.*; import org.springframework.data.annotation.Id; import org.springframework.data.redis.core.RedisHash; @@ -16,12 +17,14 @@ public final class CachedMinecraftServer implements Serializable { /** * The id of this cached server. */ - @Id @NonNull private transient final String id; + @Id @NonNull @JsonIgnore + private final String id; /** * The cached server. */ - @NonNull private final MinecraftServer value; + @NonNull + private final MinecraftServer value; /** * The unix timestamp of when this