No alert possible in SignedOutActivity

This commit is contained in:
Benoit Marty 2021-03-19 13:15:13 +01:00
parent ec50f891a2
commit 80db39a934
1 changed files with 2 additions and 0 deletions

View File

@ -26,6 +26,7 @@ import im.vector.app.R
import im.vector.app.core.platform.VectorBaseActivity import im.vector.app.core.platform.VectorBaseActivity
import im.vector.app.core.utils.isAnimationDisabled import im.vector.app.core.utils.isAnimationDisabled
import im.vector.app.features.pin.PinActivity import im.vector.app.features.pin.PinActivity
import im.vector.app.features.signout.hard.SignedOutActivity
import im.vector.app.features.themes.ThemeUtils import im.vector.app.features.themes.ThemeUtils
import timber.log.Timber import timber.log.Timber
import java.lang.ref.WeakReference import java.lang.ref.WeakReference
@ -294,6 +295,7 @@ class PopupAlertManager @Inject constructor() {
private fun shouldBeDisplayedIn(alert: VectorAlert?, activity: Activity): Boolean { private fun shouldBeDisplayedIn(alert: VectorAlert?, activity: Activity): Boolean {
return alert != null return alert != null
&& activity !is PinActivity && activity !is PinActivity
&& activity !is SignedOutActivity
&& activity is VectorBaseActivity<*> && activity is VectorBaseActivity<*>
&& alert.shouldBeDisplayedIn.invoke(activity) && alert.shouldBeDisplayedIn.invoke(activity)
} }