diff --git a/src/command/cmd_defs.c b/src/command/cmd_defs.c index 2f103d22..0947b514 100644 --- a/src/command/cmd_defs.c +++ b/src/command/cmd_defs.c @@ -516,14 +516,14 @@ static struct cmd_t command_defs[] = CMD_TAG_CHAT, CMD_TAG_GROUPCHAT) CMD_SYN( - "/status set []", + "/status set [\"\"]", "/status get |") CMD_DESC( "/status get: Find out a contact, or room members presence information. " "/status set: set own status.") CMD_ARGS( { "", "Own status. Possible values: chat, online, away, dnd, xa" }, - { "", "Optional message to use with the status." }, + { "", "Optional message to use with the status. Needs quotation marks if it's more than one word." }, { "", "The contact who's presence you which to see." }, { "", "If in a chat room, the occupant who's presence you wish to see." }) CMD_EXAMPLES( diff --git a/src/command/cmd_funcs.c b/src/command/cmd_funcs.c index f665bae1..4e3314ac 100644 --- a/src/command/cmd_funcs.c +++ b/src/command/cmd_funcs.c @@ -8078,8 +8078,12 @@ _update_presence(const resource_presence_t resource_presence, { char *msg = NULL; int num_args = g_strv_length(args); + + // if no message, use status as message if (num_args == 2) { msg = args[1]; + } else { + msg = args[2]; } jabber_conn_status_t conn_status = connection_get_status();