mirror of
https://github.com/M66B/FairEmail.git
synced 2025-03-03 02:05:36 +00:00
Fixed lifecycle owners
This commit is contained in:
parent
28d93cf785
commit
581e6eb50b
2 changed files with 3 additions and 3 deletions
|
@ -182,7 +182,7 @@ public class FragmentCompose extends Fragment {
|
|||
bottom_navigation.getMenu().findItem(R.id.action_delete).setVisible(id > 0);
|
||||
bottom_navigation.getMenu().setGroupEnabled(0, false);
|
||||
|
||||
DB.getInstance(getContext()).identity().liveIdentities(true).observe(getActivity(), new Observer<List<EntityIdentity>>() {
|
||||
DB.getInstance(getContext()).identity().liveIdentities(true).observe(FragmentCompose.this, new Observer<List<EntityIdentity>>() {
|
||||
@Override
|
||||
public void onChanged(@Nullable final List<EntityIdentity> identities) {
|
||||
Collections.sort(identities, new Comparator<EntityIdentity>() {
|
||||
|
|
|
@ -82,7 +82,7 @@ public class FragmentSetup extends Fragment {
|
|||
btnAccount.setEnabled(false);
|
||||
pbAccount.setVisibility(View.VISIBLE);
|
||||
|
||||
DB.getInstance(getContext()).account().liveFirstAccount().observe(getActivity(), new Observer<EntityAccount>() {
|
||||
DB.getInstance(getContext()).account().liveFirstAccount().observe(FragmentSetup.this, new Observer<EntityAccount>() {
|
||||
@Override
|
||||
public void onChanged(@Nullable EntityAccount account) {
|
||||
btnAccount.setEnabled(true);
|
||||
|
@ -116,7 +116,7 @@ public class FragmentSetup extends Fragment {
|
|||
btnIdentity.setEnabled(false);
|
||||
pbIdentity.setVisibility(View.VISIBLE);
|
||||
|
||||
DB.getInstance(getContext()).identity().liveFirstIdentity().observe(getActivity(), new Observer<EntityIdentity>() {
|
||||
DB.getInstance(getContext()).identity().liveFirstIdentity().observe(FragmentSetup.this, new Observer<EntityIdentity>() {
|
||||
@Override
|
||||
public void onChanged(@Nullable EntityIdentity identity) {
|
||||
btnIdentity.setEnabled(true);
|
||||
|
|
Loading…
Reference in a new issue