aboutsummaryrefslogtreecommitdiffstats
path: root/src/main
diff options
context:
space:
mode:
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/de/pixart/messenger/ui/UriHandlerActivity.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/main/java/de/pixart/messenger/ui/UriHandlerActivity.java b/src/main/java/de/pixart/messenger/ui/UriHandlerActivity.java
index d71feb3f7..47355ecba 100644
--- a/src/main/java/de/pixart/messenger/ui/UriHandlerActivity.java
+++ b/src/main/java/de/pixart/messenger/ui/UriHandlerActivity.java
@@ -104,11 +104,14 @@ public class UriHandlerActivity extends AppCompatActivity {
intent.setAction(Intent.ACTION_VIEW);
intent.putExtra("jid", xmppUri.getJid().toBareJid().toString());
intent.setData(uri);
- } else {
+ } else if (xmppUri.isJidValid()) {
intent = new Intent(getApplicationContext(), StartConversationActivity.class);
intent.setAction(Intent.ACTION_VIEW);
intent.setFlags(Intent.FLAG_ACTIVITY_REORDER_TO_FRONT);
intent.setData(uri);
+ } else {
+ Toast.makeText(this, R.string.invalid_jid, Toast.LENGTH_SHORT).show();
+ return;
}
startActivity(intent);