Fix don't asking for phone number if the domain is not a linphone domain

This commit is contained in:
Erwan Croze 2017-02-27 13:50:54 +01:00
parent 54aed57e04
commit 310187deb0

View file

@ -168,8 +168,12 @@ private static AssistantActivity instance;
if (address != null && address.asString().equals(cfg.getAddress().asString()) ) {
if (state == RegistrationState.RegistrationOk) {
if (progress != null) progress.dismiss();
if (LinphoneManager.getLc().getDefaultProxyConfig() != null) {
if (getResources().getBoolean(R.bool.use_phone_number_validation)
&& cfg.getDomain().equals(getString(R.string.default_domain))
&& LinphoneManager.getLc().getDefaultProxyConfig() != null) {
accountCreator.isAccountUsed();
} else {
success();
}
} else if (state == RegistrationState.RegistrationFailed) {
if (progress != null) progress.dismiss();