mirror of
https://github.com/AsamK/signal-cli
synced 2025-08-29 10:30:38 +00:00
Fix formatting
This commit is contained in:
parent
2c86b0bd9a
commit
1781984221
6 changed files with 10 additions and 8 deletions
|
@ -3,13 +3,15 @@ package cli;
|
|||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
|
||||
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
|
||||
import org.whispersystems.libaxolotl.*;
|
||||
import org.whispersystems.libaxolotl.AxolotlAddress;
|
||||
import org.whispersystems.libaxolotl.IdentityKey;
|
||||
import org.whispersystems.libaxolotl.IdentityKeyPair;
|
||||
import org.whispersystems.libaxolotl.InvalidKeyIdException;
|
||||
import org.whispersystems.libaxolotl.state.AxolotlStore;
|
||||
import org.whispersystems.libaxolotl.state.PreKeyRecord;
|
||||
import org.whispersystems.libaxolotl.state.SessionRecord;
|
||||
import org.whispersystems.libaxolotl.state.SignedPreKeyRecord;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.List;
|
||||
|
||||
class JsonAxolotlStore implements AxolotlStore {
|
||||
|
|
|
@ -69,7 +69,7 @@ class JsonIdentityKeyStore implements IdentityKeyStore {
|
|||
String trustedKeyName = trustedKey.get("name").asText();
|
||||
try {
|
||||
trustedKeyMap.put(trustedKeyName, new IdentityKey(Base64.decode(trustedKey.get("identityKey").asText()), 0));
|
||||
} catch (InvalidKeyException | IOException e) {
|
||||
} catch (InvalidKeyException | IOException e) {
|
||||
System.out.println(String.format("Error while decoding key for: %s", trustedKeyName));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -66,7 +66,7 @@ class JsonPreKeyStore implements PreKeyStore {
|
|||
Integer preKeyId = preKey.get("id").asInt();
|
||||
try {
|
||||
preKeyMap.put(preKeyId, Base64.decode(preKey.get("record").asText()));
|
||||
} catch (IOException e) {
|
||||
} catch (IOException e) {
|
||||
System.out.println(String.format("Error while decoding prekey for: %s", preKeyId));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -87,7 +87,7 @@ class JsonSessionStore implements SessionStore {
|
|||
String sessionName = session.get("name").asText();
|
||||
try {
|
||||
sessionMap.put(new AxolotlAddress(sessionName, session.get("deviceId").asInt()), Base64.decode(session.get("record").asText()));
|
||||
} catch (IOException e) {
|
||||
} catch (IOException e) {
|
||||
System.out.println(String.format("Error while decoding session for: %s", sessionName));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -83,7 +83,7 @@ class JsonSignedPreKeyStore implements SignedPreKeyStore {
|
|||
Integer preKeyId = preKey.get("id").asInt();
|
||||
try {
|
||||
preKeyMap.put(preKeyId, Base64.decode(preKey.get("record").asText()));
|
||||
} catch (IOException e) {
|
||||
} catch (IOException e) {
|
||||
System.out.println(String.format("Error while decoding prekey for: %s", preKeyId));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -56,8 +56,8 @@ class Manager {
|
|||
private final static String URL = "https://textsecure-service.whispersystems.org";
|
||||
private final static TrustStore TRUST_STORE = new WhisperTrustStore();
|
||||
|
||||
public final static String PROJECT_NAME = Manager.class.getPackage().getImplementationTitle();
|
||||
public final static String PROJECT_VERSION = Manager.class.getPackage().getImplementationVersion();
|
||||
public final static String PROJECT_NAME = Manager.class.getPackage().getImplementationTitle();
|
||||
public final static String PROJECT_VERSION = Manager.class.getPackage().getImplementationVersion();
|
||||
private final static String USER_AGENT = PROJECT_NAME + " " + PROJECT_VERSION;
|
||||
|
||||
private final static String settingsPath = System.getProperty("user.home") + "/.config/textsecure";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue