diff --git a/gen_stats b/gen_stats index 3338887..4fd53be 100755 --- a/gen_stats +++ b/gen_stats @@ -18,6 +18,9 @@ channels = [] for schannel in schannels: channel = dict(name=schannel.findall("channelname")[0].text,usercount=int(schannel.findall("usercount")[0].text)) channel["topic"] = schannel.findall("./channeltopic/topictext")[0].text if schannel.findall("./channeltopic/topictext")[0].text is not None else "No topic set" + # bugfix: if mode s is set and there's a topic, hide the topic + if "s" in schannel.findall("./channelmodes")[0].text.split()[0] and channel["topic"]!="No topic set": + channel["topic"]="Topic hidden" if channel["name"]=="#secret-sudoers": # no stat output for #secret-sudoers! it's a sekrit club of the ~team sysadmins! continue channels.append(channel)