Fix profile fetch crash when skipping debounce.

This commit is contained in:
Cody Henthorne
2026-05-24 10:32:58 -04:00
parent 792d86f4d8
commit c1b3fb6d1b
@@ -773,7 +773,7 @@ open class RecipientTable(context: Context, databaseHelper: SignalDatabase) : Da
return emptyList()
}
val prefix = "($ACI_COLUMN NOT NULL OR $PNI_COLUMN NOT NULL) ${if (debounceThreshold != null) " AND ($LAST_PROFILE_FETCH < ${debounceThreshold.inWholeMilliseconds}) AND " else ""}"
val prefix = "($ACI_COLUMN NOT NULL OR $PNI_COLUMN NOT NULL) AND ${if (debounceThreshold != null) " ($LAST_PROFILE_FETCH < ${debounceThreshold.inWholeMilliseconds}) AND " else ""}"
val idQuery = SqlUtil.buildFastCollectionQuery(ID, ids, prefix)
return readableDatabase