mirror of https://github.com/M66B/FairEmail.git
Prevent crash
This commit is contained in:
parent
ab057d1d6b
commit
6198761d42
|
@ -337,7 +337,11 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB
|
||||||
private Runnable checkIntent = new Runnable() {
|
private Runnable checkIntent = new Runnable() {
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
|
if (!getLifecycle().getCurrentState().isAtLeast(Lifecycle.State.RESUMED))
|
||||||
|
return;
|
||||||
|
|
||||||
Intent intent = getIntent();
|
Intent intent = getIntent();
|
||||||
|
|
||||||
String action = intent.getAction();
|
String action = intent.getAction();
|
||||||
Log.i(Helper.TAG, "View intent=" + intent + " action=" + action);
|
Log.i(Helper.TAG, "View intent=" + intent + " action=" + action);
|
||||||
if (action != null) {
|
if (action != null) {
|
||||||
|
@ -359,7 +363,7 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (getIntent().hasExtra(Intent.EXTRA_PROCESS_TEXT)) {
|
if (intent.hasExtra(Intent.EXTRA_PROCESS_TEXT)) {
|
||||||
String search = getIntent().getCharSequenceExtra(Intent.EXTRA_PROCESS_TEXT).toString();
|
String search = getIntent().getCharSequenceExtra(Intent.EXTRA_PROCESS_TEXT).toString();
|
||||||
|
|
||||||
intent.removeExtra(Intent.EXTRA_PROCESS_TEXT);
|
intent.removeExtra(Intent.EXTRA_PROCESS_TEXT);
|
||||||
|
|
Loading…
Reference in New Issue