Fixed uris so in case there's no additional the data one (with zips) is selected instead

This commit is contained in:
Viktor De Pasquale 2019-07-10 17:24:57 +02:00 committed by John Wu
parent 011539f6f1
commit b2048379af

View File

@ -18,7 +18,7 @@ open class FlashActivity : MagiskActivity<FlashViewModel, ActivityFlashBinding>(
override val layoutRes: Int = R.layout.activity_flash
override val viewModel: FlashViewModel by viewModel {
val uri = intent.data ?: let { finish(); Uri.EMPTY }
val additionalUri = intent.getParcelableExtra<Uri>(Const.Key.FLASH_DATA) ?: Uri.EMPTY
val additionalUri = intent.getParcelableExtra<Uri>(Const.Key.FLASH_DATA) ?: uri
val action = intent.getStringExtra(Const.Key.FLASH_ACTION) ?: let { finish();"" }
parametersOf(action, uri, additionalUri)
}