Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 68d63870 authored by Chaohui Wang's avatar Chaohui Wang
Browse files

Fix Data Saver page crashed when rotate

This is because before fix mLoadAppRunnable is async run. And the
getContext() within it will return null when the Fragment in some not
ready lifecycle.

Use viewLifecycleOwner.lifecycleScope.launch to ensure the async
function will only be run when the view is ready, and automatically
canceled when out of scope.

Since this requires Kotlin Coroutine so migrate DataSaverSummary to
Kotlin, other functionality are keep no change.

Fix: 279863347
Test: Manual
Change-Id: I2e97a071c103e63b3306b801fc38f4704e3be0d2
parent 2b44fc26
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment