Ensure that the unknown UUID does not create an entry.
This commit is contained in:
parent
ccff7b1148
commit
ef86372635
1 changed files with 4 additions and 0 deletions
|
@ -151,6 +151,10 @@ public class Recipient {
|
|||
*/
|
||||
@WorkerThread
|
||||
public static @NonNull Recipient externalPush(@NonNull Context context, @Nullable UUID uuid, @Nullable String e164) {
|
||||
if (UuidUtil.UNKNOWN_UUID.equals(uuid)) {
|
||||
throw new AssertionError();
|
||||
}
|
||||
|
||||
RecipientDatabase db = DatabaseFactory.getRecipientDatabase(context);
|
||||
Optional<RecipientId> uuidUser = uuid != null ? db.getByUuid(uuid) : Optional.absent();
|
||||
Optional<RecipientId> e164User = e164 != null ? db.getByE164(e164) : Optional.absent();
|
||||
|
|
Loading…
Add table
Reference in a new issue