mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-22 01:40:07 +01:00
Implement the message send log for sender key retries.
This commit is contained in:
committed by
Cody Henthorne
parent
6502ef64ce
commit
f19033a7a2
@@ -68,8 +68,8 @@ public class Data {
|
||||
}
|
||||
|
||||
public byte[] getStringAsBlob(@NonNull String key) {
|
||||
throwIfAbsent(strings, key);
|
||||
return Base64.decodeOrThrow(strings.get(key));
|
||||
String raw = getString(key);
|
||||
return raw != null ? Base64.decodeOrThrow(raw) : null;
|
||||
}
|
||||
|
||||
public String getStringOrDefault(@NonNull String key, String defaultValue) {
|
||||
@@ -356,8 +356,8 @@ public class Data {
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder putBlobAsString(@NonNull String key, @NonNull byte[] value) {
|
||||
String serialized = Base64.encodeBytes(value);
|
||||
public Builder putBlobAsString(@NonNull String key, @Nullable byte[] value) {
|
||||
String serialized = value != null ? Base64.encodeBytes(value) : null;
|
||||
strings.put(key, serialized);
|
||||
return this;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user