fix(compose-content-type-menu): hopefully fix a crash on this thing being null

Fuck java
This commit is contained in:
LucasGGamerM
2024-05-18 13:43:06 -03:00
parent 711c70af2f
commit 44e3e5faaf

View File

@@ -512,6 +512,7 @@ public class ComposeFragment extends MastodonToolbarFragment implements OnBackPr
}
int typeIndex=contentType.ordinal();
if (contentTypePopup.getMenu().findItem(typeIndex) != null)
contentTypePopup.getMenu().findItem(typeIndex).setChecked(true);
contentTypeBtn.setSelected(typeIndex != ContentType.UNSPECIFIED.ordinal() && typeIndex != ContentType.PLAIN.ordinal());