test
This commit is contained in:
parent
273507ea6f
commit
6f4d032a19
1 changed files with 4 additions and 8 deletions
|
@ -396,10 +396,7 @@ public class MainActivity extends AppCompatActivity implements PostRequestCallba
|
||||||
if(!isSimConnected(context, phone.telephonyManager))
|
if(!isSimConnected(context, phone.telephonyManager))
|
||||||
nextPhone();
|
nextPhone();
|
||||||
else
|
else
|
||||||
if(!ussd.has(phone.operator))
|
requestUssdNumber(phone);
|
||||||
nextPhone();
|
|
||||||
else
|
|
||||||
requestUssdNumber(phone);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -452,9 +449,8 @@ public class MainActivity extends AppCompatActivity implements PostRequestCallba
|
||||||
} else if (result.get("name"). // STATIC
|
} else if (result.get("name"). // STATIC
|
||||||
equals("languages")) { // STATIC
|
equals("languages")) { // STATIC
|
||||||
String currentLanguage = Locale.getDefault().getLanguage();
|
String currentLanguage = Locale.getDefault().getLanguage();
|
||||||
if(!result.getJSONObject("data").has(currentLanguage)) // STATIC
|
if(!result.getJSONObject("data").has(currentLanguage))
|
||||||
currentLanguage = "en"; // STATIC
|
currentLanguage = "en";
|
||||||
|
|
||||||
language = result.getJSONObject(
|
language = result.getJSONObject(
|
||||||
"data" // STATIC
|
"data" // STATIC
|
||||||
).getJSONObject(currentLanguage);
|
).getJSONObject(currentLanguage);
|
||||||
|
@ -468,7 +464,7 @@ public class MainActivity extends AppCompatActivity implements PostRequestCallba
|
||||||
requestPermissions(retrievePermissions(this));
|
requestPermissions(retrievePermissions(this));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (JSONException e) {
|
||||||
// Log.i("ww", Arrays.toString(e.getStackTrace()));
|
// Log.i("ww", Arrays.toString(e.getStackTrace()));
|
||||||
throw new RuntimeException(e);
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue