remove prosody push from blacklist
This commit is contained in:
parent
49365511e4
commit
bc9da1fbf4
|
@ -1553,8 +1553,7 @@ public class ConversationActivity extends XmppActivity
|
||||||
|
|
||||||
private boolean hasAccountWithoutPush() {
|
private boolean hasAccountWithoutPush() {
|
||||||
for(Account account : xmppConnectionService.getAccounts()) {
|
for(Account account : xmppConnectionService.getAccounts()) {
|
||||||
if (account.getStatus() != Account.State.DISABLED
|
if (account.getStatus() != Account.State.DISABLED && !xmppConnectionService.getPushManagementService().available(account)) {
|
||||||
&& !xmppConnectionService.getPushManagementService().availableAndUseful(account)) {
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -861,7 +861,7 @@ public class EditAccountActivity extends OmemoActivity implements OnAccountUpdat
|
||||||
if (this.mAccount.isOnlineAndConnected() && !this.mFetchingAvatar) {
|
if (this.mAccount.isOnlineAndConnected() && !this.mFetchingAvatar) {
|
||||||
Features features = this.mAccount.getXmppConnection().getFeatures();
|
Features features = this.mAccount.getXmppConnection().getFeatures();
|
||||||
this.mStats.setVisibility(View.VISIBLE);
|
this.mStats.setVisibility(View.VISIBLE);
|
||||||
boolean showBatteryWarning = !xmppConnectionService.getPushManagementService().availableAndUseful(mAccount) && isOptimizingBattery();
|
boolean showBatteryWarning = !xmppConnectionService.getPushManagementService().available(mAccount) && isOptimizingBattery();
|
||||||
boolean showDataSaverWarning = isAffectedByDataSaver();
|
boolean showDataSaverWarning = isAffectedByDataSaver();
|
||||||
showOsOptimizationWarning(showBatteryWarning,showDataSaverWarning);
|
showOsOptimizationWarning(showBatteryWarning,showDataSaverWarning);
|
||||||
this.mSessionEst.setText(UIHelper.readableTimeDifferenceFull(this, this.mAccount.getXmppConnection()
|
this.mSessionEst.setText(UIHelper.readableTimeDifferenceFull(this, this.mAccount.getXmppConnection()
|
||||||
|
|
|
@ -8,9 +8,6 @@ public class Patches {
|
||||||
public static final List<String> DISCO_EXCEPTIONS = Arrays.asList(
|
public static final List<String> DISCO_EXCEPTIONS = Arrays.asList(
|
||||||
"nimbuzz.com"
|
"nimbuzz.com"
|
||||||
);
|
);
|
||||||
public static final List<XmppConnection.Identity> SUFFICIENT_PUSH = Arrays.asList(
|
|
||||||
XmppConnection.Identity.EJABBERD
|
|
||||||
);
|
|
||||||
public static final List<XmppConnection.Identity> BAD_MUC_REFLECTION = Arrays.asList(
|
public static final List<XmppConnection.Identity> BAD_MUC_REFLECTION = Arrays.asList(
|
||||||
XmppConnection.Identity.SLACK
|
XmppConnection.Identity.SLACK
|
||||||
);
|
);
|
||||||
|
|
|
@ -110,10 +110,6 @@ public class PushManagementService {
|
||||||
&& playServicesAvailable();
|
&& playServicesAvailable();
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean availableAndUseful(Account account) {
|
|
||||||
return Patches.SUFFICIENT_PUSH.contains(account.getServerIdentity()) && available(account);
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean playServicesAvailable() {
|
private boolean playServicesAvailable() {
|
||||||
return GoogleApiAvailability.getInstance().isGooglePlayServicesAvailable(mXmppConnectionService) == ConnectionResult.SUCCESS;
|
return GoogleApiAvailability.getInstance().isGooglePlayServicesAvailable(mXmppConnectionService) == ConnectionResult.SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue