catch exceptions thrown at getting recycle bin files in the settings
This commit is contained in:
parent
23d6fd110d
commit
804eb08143
1 changed files with 4 additions and 1 deletions
|
@ -573,7 +573,10 @@ class SettingsActivity : SimpleActivity() {
|
||||||
|
|
||||||
private fun setupEmptyRecycleBin() {
|
private fun setupEmptyRecycleBin() {
|
||||||
Thread {
|
Thread {
|
||||||
mRecycleBinContentSize = galleryDB.MediumDao().getDeletedMedia().sumByLong { it.size }
|
try {
|
||||||
|
mRecycleBinContentSize = galleryDB.MediumDao().getDeletedMedia().sumByLong { it.size }
|
||||||
|
} catch (ignored: Exception) {
|
||||||
|
}
|
||||||
runOnUiThread {
|
runOnUiThread {
|
||||||
settings_empty_recycle_bin_size.text = mRecycleBinContentSize.formatSize()
|
settings_empty_recycle_bin_size.text = mRecycleBinContentSize.formatSize()
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue