1
0
Fork 0
mirror of https://github.com/ACINQ/eclair.git synced 2025-03-12 19:01:39 +01:00

Filter out non-successful payments in list-all-incoming query

This commit is contained in:
dpad85 2022-07-04 15:09:04 +02:00
parent 5cbd6eb923
commit f10e710800
No known key found for this signature in database
GPG key ID: 574C8C6A1673E987

View file

@ -343,7 +343,7 @@ class SqlitePaymentsDb(sqlite: Connection) extends PaymentsDb with Logging {
}
def listAllIncomingPayments(): Seq[IncomingPayment] = withMetrics("payments/list-incoming") {
using(sqlite.prepareStatement("SELECT * FROM received_payments")) { statement =>
using(sqlite.prepareStatement("SELECT * FROM received_payments where received_msat > 0")) { statement =>
val rs = statement.executeQuery()
var q: Queue[IncomingPayment] = Queue()
while (rs.next()) {