mirror of
https://github.com/f-droid/fdroidclient.git
synced 2026-02-19 07:35:36 -05:00
Don't finish() explicitly
We are already observing the ViewModel. Once the repo becomes null in the ViewModel.repoFlow, the observer will finish().
This commit is contained in:
@@ -133,9 +133,9 @@ class RepoDetailsActivity : AppCompatActivity() {
|
||||
MaterialAlertDialogBuilder(this)
|
||||
.setTitle(R.string.repo_confirm_delete_title)
|
||||
.setMessage(R.string.repo_confirm_delete_body)
|
||||
.setPositiveButton(R.string.delete) { _, _ ->
|
||||
.setPositiveButton(R.string.delete) { dialog, _ ->
|
||||
viewModel.deleteRepository()
|
||||
finish()
|
||||
dialog.dismiss()
|
||||
}
|
||||
.setNegativeButton(android.R.string.cancel, null)
|
||||
.show()
|
||||
|
||||
Reference in New Issue
Block a user