Call restart() extension

This commit is contained in:
Benoit Marty 2020-08-24 15:50:47 +02:00
parent efa3aa5cf8
commit 116e6fb3c0
1 changed files with 3 additions and 3 deletions

View File

@ -60,6 +60,7 @@ import im.vector.app.core.dialogs.UnrecognizedCertificateDialog
import im.vector.app.core.extensions.exhaustive
import im.vector.app.core.extensions.observeEvent
import im.vector.app.core.extensions.observeNotNull
import im.vector.app.core.extensions.restart
import im.vector.app.core.extensions.vectorComponent
import im.vector.app.core.utils.toast
import im.vector.app.features.MainActivity
@ -79,10 +80,10 @@ import im.vector.app.features.settings.VectorPreferences
import im.vector.app.features.themes.ActivityOtherThemes
import im.vector.app.features.themes.ThemeUtils
import im.vector.app.receivers.DebugReceiver
import org.matrix.android.sdk.api.failure.GlobalError
import io.reactivex.android.schedulers.AndroidSchedulers
import io.reactivex.disposables.CompositeDisposable
import io.reactivex.disposables.Disposable
import org.matrix.android.sdk.api.failure.GlobalError
import timber.log.Timber
import kotlin.system.measureTimeMillis
@ -198,8 +199,7 @@ abstract class VectorBaseActivity : AppCompatActivity(), HasScreenInjector {
configurationViewModel.activityRestarter.observe(this, Observer {
if (!it.hasBeenHandled) {
// Recreate the Activity because configuration has changed
startActivity(intent)
finish()
restart()
}
})
pinLocker.getLiveState().observeNotNull(this) {