Don't store default values of group blocked/permissionDenied

This commit is contained in:
AsamK 2021-12-20 14:02:40 +01:00
parent baed2b7ead
commit dc2470d046

View file

@ -1,5 +1,6 @@
package org.asamk.signal.manager.storage.groups; package org.asamk.signal.manager.storage.groups;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.core.JsonGenerator; import com.fasterxml.jackson.core.JsonGenerator;
import com.fasterxml.jackson.core.JsonParser; import com.fasterxml.jackson.core.JsonParser;
import com.fasterxml.jackson.databind.DeserializationContext; import com.fasterxml.jackson.databind.DeserializationContext;
@ -341,7 +342,11 @@ public class GroupStore {
} }
private record GroupV2( private record GroupV2(
String groupId, String masterKey, String distributionId, boolean blocked, boolean permissionDenied String groupId,
String masterKey,
String distributionId,
@JsonInclude(JsonInclude.Include.NON_DEFAULT) boolean blocked,
@JsonInclude(JsonInclude.Include.NON_DEFAULT) boolean permissionDenied
) {} ) {}
} }