1
0
mirror of https://github.com/profanity-im/profanity.git synced 2025-01-03 14:57:42 -05:00

Show message when no group or empty roster on /who

This commit is contained in:
James Booth 2014-07-22 23:31:14 +01:00
parent fd1d540889
commit 9123675c9c

View File

@ -802,8 +802,16 @@ _who_roster(const char * const group, const char * const presence)
GSList *list = NULL;
if (group != NULL) {
list = roster_get_group(group);
if (list == NULL) {
cons_show("No such group: %s.", group);
return;
}
} else {
list = roster_get_contacts();
if (list == NULL) {
cons_show("No contacts in roster.");
return;
}
}
// no arg, show all contacts