From: David ‘Bombe’ Roden Date: Sat, 29 Apr 2023 19:39:19 +0000 (+0200) Subject: 🐛 Serialize the success value, remove equals override X-Git-Tag: v2~48 X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=ca8d94517a9edab7bc448201fca26a0489135204;p=rhynodge.git 🐛 Serialize the success value, remove equals override --- diff --git a/src/main/java/net/pterodactylus/rhynodge/states/AbstractState.java b/src/main/java/net/pterodactylus/rhynodge/states/AbstractState.java index 8828fe4..f3b37e5 100644 --- a/src/main/java/net/pterodactylus/rhynodge/states/AbstractState.java +++ b/src/main/java/net/pterodactylus/rhynodge/states/AbstractState.java @@ -46,6 +46,7 @@ public abstract class AbstractState implements State { private final long time; /** Whether the state was successfully retrieved. */ + @JsonProperty private final boolean success; private final boolean empty; diff --git a/src/test/java/net/pterodactylus/rhynodge/states/StateManagerTest.java b/src/test/java/net/pterodactylus/rhynodge/states/StateManagerTest.java index 8f250ab..da1bb90 100644 --- a/src/test/java/net/pterodactylus/rhynodge/states/StateManagerTest.java +++ b/src/test/java/net/pterodactylus/rhynodge/states/StateManagerTest.java @@ -97,17 +97,6 @@ public class StateManagerTest { super(success); } - @Override - public boolean equals(Object object) { - if (!(object instanceof TestState)) { - return false; - } - TestState testState = (TestState) object; - return equal(exception(), testState.exception()) - && (failCount() == testState.failCount()) - && (time() == testState.time()); - } - @Nonnull @Override protected String plainText() {