fix: NullPointerException crash while change post language twice

Closes https://github.com/mastodon/mastodon-android/issues/766
This commit is contained in:
JI,XIAOYONG 2024-01-25 15:54:15 +08:00
parent 48f9aabaf7
commit a65d6fbeb3
1 changed files with 1 additions and 1 deletions

View File

@ -97,7 +97,7 @@ public class ComposeLanguageAlertViewController{
int i=0; int i=0;
boolean found=false; boolean found=false;
for(SpecialLocaleInfo li:specialLocales){ for(SpecialLocaleInfo li:specialLocales){
if(li.locale.equals(previouslySelected.locale)){ if(null!=li.locale&&li.locale.equals(previouslySelected.locale)){
selectedLocale=li.locale; selectedLocale=li.locale;
selectedIndex=i; selectedIndex=i;
found=true; found=true;