Fix #143 - Avoid a crash in conversation activity

This commit is contained in:
Thomas 2022-06-08 09:17:27 +02:00
parent 9c430e4a22
commit b96996ddde

View file

@ -78,7 +78,9 @@ public class ContextActivity extends BaseActivity {
finish(); finish();
return; return;
} }
MastodonHelper.loadPPMastodon(binding.profilePicture, BaseMainActivity.accountWeakReference.get().mastodon_account); if (BaseMainActivity.accountWeakReference.get() != null) {
MastodonHelper.loadPPMastodon(binding.profilePicture, BaseMainActivity.accountWeakReference.get().mastodon_account);
}
Bundle bundle = new Bundle(); Bundle bundle = new Bundle();
new Thread(() -> { new Thread(() -> {
focusedStatus = SpannableHelper.convertStatus(getApplication().getApplicationContext(), focusedStatus); focusedStatus = SpannableHelper.convertStatus(getApplication().getApplicationContext(), focusedStatus);