Try to avoid crashing when unable to get backup filename for some reason
(cherry picked from commit be3e31ddc44d21ba185efa203f08f182df88195c)
This commit is contained in:
parent
45ef778e6d
commit
7cdda6241f
@ -203,7 +203,7 @@ class SettingsBackupController : SettingsController() {
|
||||
}
|
||||
CODE_BACKUP_RESTORE -> {
|
||||
uri?.path?.let {
|
||||
val fileName = DocumentFile.fromSingleUri(activity, uri)!!.name!!
|
||||
val fileName = DocumentFile.fromSingleUri(activity, uri)?.name ?: uri.toString()
|
||||
when {
|
||||
fileName.endsWith(".proto.gz") -> {
|
||||
val options = arrayOf(
|
||||
|
Loading…
x
Reference in New Issue
Block a user