mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-22 18:00:02 +01:00
Fix various UI bugs for chat folders.
This commit is contained in:
@@ -234,13 +234,12 @@ class ChatFolderTables(context: Context?, databaseHelper: SignalDatabase?) : Dat
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the number of user-made folders
|
||||
* Returns the number of folders a user has, including the default 'All Chats'
|
||||
*/
|
||||
fun getFolderCount(): Int {
|
||||
return readableDatabase
|
||||
.count()
|
||||
.from(ChatFolderTable.TABLE_NAME)
|
||||
.where("${ChatFolderTable.FOLDER_TYPE} != ${ChatFolderRecord.FolderType.ALL.value}")
|
||||
.run()
|
||||
.readToSingleInt()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user