1
0
mirror of https://github.com/moparisthebest/Yaaic synced 2025-01-08 12:18:07 -05:00

ConversationActivity: onCreate(): Check if server is returned by getServerById() - Fixes #55

This commit is contained in:
Sebastian Kaspari 2011-04-12 23:44:39 +02:00
parent 9387a02068
commit 4e266e1bb7

View File

@ -132,6 +132,12 @@ public class ConversationActivity extends Activity implements ServiceConnection,
serverId = getIntent().getExtras().getInt("serverId");
server = Yaaic.getInstance().getServerById(serverId);
// Finish activity if server does not exist anymore - See #55
if (server == null) {
this.finish();
}
setTitle("Yaaic - " + server.getTitle());
setContentView(R.layout.conversations);