Skip to content
This repository has been archived by the owner on Oct 27, 2020. It is now read-only.

Crash when switching between Activities #33

Open
Duna opened this issue Dec 11, 2018 · 2 comments
Open

Crash when switching between Activities #33

Duna opened this issue Dec 11, 2018 · 2 comments

Comments

@Duna
Copy link

Duna commented Dec 11, 2018

Have 2 activities and have .onDestroy dialog implementation when onDestroy activity.
Both of them initialize this library dialog at onCreate

Navigate from Activity A->B->A -> crash at onDestroy

@dhananjayprojects
Copy link

dhananjayprojects commented Apr 14, 2019

I had the same issue. It was easily solved by not putting nointernetDialog.onDestroy in onStop and just in onDestroy.

`
@OverRide
protected void onStop() {
super.onStop();
}

@Override
protected void onResume() {
    super.onResume();
    noInternetDialog = new NoInternetDialog.Builder(this).build();
}

@Override
protected void onDestroy() {
    super.onDestroy();
    noInternetDialog.onDestroy();
}`

@ImaginativeShohag
Copy link

You can try this similar library: https://github.com/ImaginativeShohag/Oops-No-Internet

# for free to subscribe to this conversation on GitHub. Already have an account? #.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants