mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-22 09:49:30 +01:00
Add call log event proto updates.
This commit is contained in:
committed by
Cody Henthorne
parent
989bd662c6
commit
6f46331772
@@ -947,12 +947,12 @@ class CallTable(context: Context, databaseHelper: SignalDatabase) : DatabaseTabl
|
||||
/**
|
||||
* Gets the most recent timestamp from the [TIMESTAMP] column
|
||||
*/
|
||||
fun getLatestTimestamp(): Long {
|
||||
fun getLatestCall(): Call? {
|
||||
val statement = """
|
||||
SELECT $TIMESTAMP FROM $TABLE_NAME ORDER BY $TIMESTAMP DESC LIMIT 1
|
||||
SELECT * FROM $TABLE_NAME ORDER BY $TIMESTAMP DESC LIMIT 1
|
||||
""".trimIndent()
|
||||
|
||||
return readableDatabase.query(statement).readToSingleLong(-1)
|
||||
return readableDatabase.query(statement).readToSingleObject { Call.deserialize(it) }
|
||||
}
|
||||
|
||||
fun deleteNonAdHocCallEventsOnOrBefore(timestamp: Long) {
|
||||
|
||||
Reference in New Issue
Block a user