mirror of
https://github.com/chubin/cheat.sh.git
synced 2026-06-20 13:16:44 +02:00
Another check if a given topic has just the :list and rosetta/
This commit is contained in:
@@ -119,6 +119,9 @@ class Router(object):
|
||||
#Here we remove the special cases
|
||||
if ":list" in topic_list: topic_list.remove(":list")
|
||||
if "rosetta/" in topic_list: topic_list.remove("rosetta/")
|
||||
#Here we still check that topic_list in not empty
|
||||
if not topic_list:
|
||||
return prefix
|
||||
random_topic = random.choice(topic_list)
|
||||
return prefix + random_topic
|
||||
|
||||
|
||||
Reference in New Issue
Block a user