about summary refs log tree commit diff stats
path: root/src/command
diff options
context:
space:
mode:
authorJames Booth <boothj5@gmail.com>2013-12-15 20:32:30 +0000
committerJames Booth <boothj5@gmail.com>2013-12-15 20:32:30 +0000
commit5e739cbfb7763ee926fbeb3cb8bd1d81f943c55e (patch)
tree8ef956628d822eb63bdc6885dedad336ba3a5aab /src/command
parent9b631cf57173f1ddf371531da16da06070d39a52 (diff)
downloadprofani-tty-5e739cbfb7763ee926fbeb3cb8bd1d81f943c55e.tar.gz
Moved fulljid logic to accounts
Diffstat (limited to 'src/command')
-rw-r--r--src/command/commands.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/src/command/commands.c b/src/command/commands.c
index 6c354ec4..910c57d5 100644
--- a/src/command/commands.c
+++ b/src/command/commands.c
@@ -72,12 +72,7 @@ cmd_connect(gchar **args, struct cmd_help_t help)
 
         ProfAccount *account = accounts_get_account(lower);
         if (account != NULL) {
-            if (account->resource != NULL) {
-                jid = create_fulljid(account->jid, account->resource);
-            } else {
-                jid = strdup(account->jid);
-            }
-
+            jid = accounts_create_full_jid(account);
             if (account->password == NULL) {
                 account->password = ui_ask_password();
             }