mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-22 01:40:07 +01:00
Fix payments spinning forever.
This commit is contained in:
committed by
Greyson Parrelli
parent
6a21106347
commit
b83080e2d7
@@ -417,6 +417,16 @@ public final class PaymentTable extends DatabaseTable implements RecipientIdData
|
||||
return payments;
|
||||
}
|
||||
|
||||
public @NonNull List<UUID> getSubmittedIncomingPayments() {
|
||||
return CursorExtensionsKt.readToList(
|
||||
SQLiteDatabaseExtensionsKt.select(getReadableDatabase(), PAYMENT_UUID)
|
||||
.from(TABLE_NAME)
|
||||
.where(DIRECTION + " = ? AND " + STATE + " = ?", Direction.RECEIVED.serialize(), State.SUBMITTED.serialize())
|
||||
.run(),
|
||||
c -> UuidUtil.parseOrNull(CursorUtil.requireString(c, PAYMENT_UUID))
|
||||
);
|
||||
}
|
||||
|
||||
@AnyThread
|
||||
public @NonNull LiveData<List<PaymentTransaction>> getAllLive() {
|
||||
return LiveDataUtil.mapAsync(changeSignal, change -> getAll());
|
||||
|
||||
Reference in New Issue
Block a user