Commit c56baa34 authored by Finn Herzfeld's avatar Finn Herzfeld 🌵

Remove redundant trusted key add

parent ca0b8dcc
Pipeline #4065 failed with stages
in 73 minutes and 43 seconds
......@@ -114,10 +114,6 @@ public class IdentityKeyStore implements org.whispersystems.libsignal.state.Iden
*/
public boolean saveIdentity(SignalServiceAddress address, IdentityKey identityKey, TrustLevel trustLevel, Date added) {
List<IdentityKeyStore.Identity> identities = getKeys(address);
if(identities.size() == 0) {
trustedKeys.add(new Identity(address, identityKey, trustLevel, added != null ? added : new Date()));
return false;
}
for(IdentityKeyStore.Identity id : identities) {
if(!id.identityKey.equals(identityKey)) {
......
......@@ -153,9 +153,7 @@ public class SessionStore implements org.whispersystems.libsignal.state.SessionS
@Override
public SessionStore deserialize(JsonParser jsonParser, DeserializationContext deserializationContext) throws IOException {
JsonNode tree = jsonParser.getCodec().readTree(jsonParser);
SessionStore sessionStore = new SessionStore();
if (tree.isArray()) {
for (JsonNode node : tree) {
SessionInfo sessionInfo = mapper.treeToValue(node, SessionInfo.class);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment