From a2e8e6bc4b1fa7a6b478ce699356bb3ab805492b Mon Sep 17 00:00:00 2001 From: Christian Schneppe Date: Tue, 24 Apr 2018 21:27:11 +0200 Subject: no WelcomeActivity if MAGIC_CREATE_DOMAIN is unset --- src/main/java/de/pixart/messenger/ui/EditAccountActivity.java | 2 +- src/main/java/de/pixart/messenger/ui/UriHandlerActivity.java | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) (limited to 'src/main/java') diff --git a/src/main/java/de/pixart/messenger/ui/EditAccountActivity.java b/src/main/java/de/pixart/messenger/ui/EditAccountActivity.java index 1a463b18a..7aa352342 100644 --- a/src/main/java/de/pixart/messenger/ui/EditAccountActivity.java +++ b/src/main/java/de/pixart/messenger/ui/EditAccountActivity.java @@ -324,7 +324,7 @@ public class EditAccountActivity extends OmemoActivity implements OnAccountUpdat if (mInitMode && mAccount != null && !mAccount.isOptionSet(Account.OPTION_LOGGED_IN_SUCCESSFULLY)) { xmppConnectionService.deleteAccount(mAccount); } - if (xmppConnectionService.getAccounts().size() == 0) { + if (xmppConnectionService.getAccounts().size() == 0 && Config.MAGIC_CREATE_DOMAIN != null) { Intent intent = new Intent(EditAccountActivity.this, WelcomeActivity.class); WelcomeActivity.addInviteUri(intent, getIntent()); startActivity(intent); diff --git a/src/main/java/de/pixart/messenger/ui/UriHandlerActivity.java b/src/main/java/de/pixart/messenger/ui/UriHandlerActivity.java index 39aacd182..776973c09 100644 --- a/src/main/java/de/pixart/messenger/ui/UriHandlerActivity.java +++ b/src/main/java/de/pixart/messenger/ui/UriHandlerActivity.java @@ -13,6 +13,7 @@ import android.widget.Toast; import java.util.List; +import de.pixart.messenger.Config; import de.pixart.messenger.R; import de.pixart.messenger.persistance.DatabaseBackend; import de.pixart.messenger.utils.XmppUri; @@ -89,7 +90,7 @@ public class UriHandlerActivity extends AppCompatActivity { return; } - if (accounts.size() == 0) { + if (accounts.size() == 0 && Config.MAGIC_CREATE_DOMAIN != null) { intent = new Intent(getApplicationContext(), WelcomeActivity.class); WelcomeActivity.addInviteUri(intent, xmppUri); startActivity(intent); -- cgit v1.2.3