Make /hilight list be specific with regards to -nick/-word/-line, v3, logic improvements

This commit is contained in:
Jari Matilainen 2015-10-04 17:54:58 +02:00
commit b6cd02019b

View file

@ -484,13 +484,12 @@ static void hilight_print(int index, HILIGHT_REC *rec)
GString *options; GString *options;
options = g_string_new(NULL); options = g_string_new(NULL);
if (!(rec->nick && rec->word)) { if (!(rec->nick && rec->word))
g_string_append(options, "-line ");
else {
if (rec->nick) g_string_append(options, "-nick "); if (rec->nick) g_string_append(options, "-nick ");
if (rec->word) g_string_append(options, "-word "); if (rec->word) g_string_append(options, "-word ");
} }
else {
g_string_append(options, "-line ");
}
if (rec->nickmask) g_string_append(options, "-mask "); if (rec->nickmask) g_string_append(options, "-mask ");
if (rec->fullword) g_string_append(options, "-full "); if (rec->fullword) g_string_append(options, "-full ");