aboutsummaryrefslogtreecommitdiffstats
path: root/protocols/twitter/twitter.c
diff options
context:
space:
mode:
Diffstat (limited to 'protocols/twitter/twitter.c')
-rw-r--r--protocols/twitter/twitter.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/protocols/twitter/twitter.c b/protocols/twitter/twitter.c
index 70e11067..2a6ae88f 100644
--- a/protocols/twitter/twitter.c
+++ b/protocols/twitter/twitter.c
@@ -322,7 +322,7 @@ static void twitter_init(account_t * acc)
s = set_add(&acc->set, "show_ids", "true", set_eval_bool, acc);
- s = set_add(&acc->set, "show_old_mentions", "20", set_eval_int, acc);
+ s = set_add(&acc->set, "show_old_mentions", "0", set_eval_int, acc);
s = set_add(&acc->set, "strip_newlines", "false", set_eval_bool, acc);
@@ -601,7 +601,7 @@ static void twitter_handle_command(struct im_connection *ic, char *message)
bee_user_t *bu = NULL;
cmds = g_strdup(message);
- cmd = split_command_parts(cmds);
+ cmd = split_command_parts(cmds, 2);
if (cmd[0] == NULL) {
goto eof;
@@ -616,7 +616,9 @@ static void twitter_handle_command(struct im_connection *ic, char *message)
twitter_log(ic, "Could not undo last action");
goto eof;
- } else if (g_strcasecmp(cmd[0], "favourite") == 0 && cmd[1]) {
+ } else if ((g_strcasecmp(cmd[0], "favourite") == 0 ||
+ g_strcasecmp(cmd[0], "favorite") == 0 ||
+ g_strcasecmp(cmd[0], "fav") == 0) && cmd[1]) {
if ((id = twitter_message_id_from_command_arg(ic, cmd[1], NULL))) {
twitter_favourite_tweet(ic, id);
} else {
@@ -661,7 +663,7 @@ static void twitter_handle_command(struct im_connection *ic, char *message)
"post any statuses recently", cmd[1]);
goto eof;
}
- message = new = g_strdup_printf("@%s %s", bu->handle, message + (cmd[2] - cmd[0]));
+ message = new = g_strdup_printf("@%s %s", bu->handle, cmd[2]);
in_reply_to = id;
allow_post = TRUE;
} else if (g_strcasecmp(cmd[0], "post") == 0) {