mirror of
https://github.com/signalapp/Signal-Android.git
synced 2025-12-23 20:48:43 +00:00
Fix potential crash if snackbar action is processed when fragment is not attached.
This commit is contained in:
committed by
Cody Henthorne
parent
80fc40bbc2
commit
05326acadc
@@ -144,7 +144,7 @@ class MediaPreviewV2Fragment :
|
||||
Log.w(TAG, "Unsupported media type sent to MediaPreviewV2Fragment, finishing.")
|
||||
Snackbar.make(binding.root, R.string.MediaPreviewActivity_unssuported_media_type, Snackbar.LENGTH_LONG)
|
||||
.setAction(R.string.MediaPreviewActivity_dismiss_due_to_error) {
|
||||
requireActivity().finish()
|
||||
activity?.finish()
|
||||
}.show()
|
||||
}
|
||||
viewModel.initialize(args.showThread, args.allMediaInRail, args.leftIsRecent)
|
||||
|
||||
Reference in New Issue
Block a user