Skip to content
Extraits de code Groupes Projets
Valider 37b24b44 rédigé par Loïc Wikle DUBARD's avatar Loïc Wikle DUBARD
Parcourir les fichiers

change title of thread possible

parent c1905d46
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
......@@ -56,10 +56,11 @@ class Bot(Client):
'!kohlanta <nom>\n' + \
'!rateau \n' + \
'!maps <nom_du_lieu> <destination(facultatif)> ... not yet fully fonctionnal\n' + \
'!memes <image_name_or_url> ; <texte1> ; <texte2(facultatif)> ... not yet implemented\n' + \
'!memes <image_name_or_url> ; <texte1> ; <texte2(facultatif)>\n' + \
'!ping \n' + \
'!translate <phrase> ; <lang_source> ; <lang_dest>\n' + \
'!shitpostbot5000 [status|on|off|random <keyword(facultatif)>] ... ne pas utiliser PLEASE\n' + \
'!title <newtitle>\n'\
'!about -> vas-y test-moi !\n'
return help_text
elif '!translate' in texte:
......@@ -80,6 +81,9 @@ class Bot(Client):
elif texte == '!haddock':
return useless.haddock()
elif '!title ' in texte:
texte = texte.replace("!title ", '')
client.changeThreadTitle(texte, thread_id=thread_id, thread_type=thread_type)
# renomer qqn
elif '!rename' in texte:
texte = texte.replace('!rename ', '').split(';')
......
......@@ -60,7 +60,7 @@ class Shitpostbot5000(object):
@classmethod
def random(self, hashtag=''):
if hashtag.strip() == '':
hashtag = random.choice(['shitpostmeme', 'shitpost', 'shitposts', 'memes'])
hashtag = random.choice(['shitpostmeme', 'shitpost', 'shitposts', 'memes', 'dank', 'dankmemes', 'dankdank', 'dankmemesdaily', 'dankest', 'dankymemes', 'danks', 'dankhumor', 'dankmemez', 'dankmems', 'dankmeme'])
elif hashtag.strip() == 'climbing':
hashtag = random.choice(['climbingmemes', 'rockclimbingmemes', 'climbingmemesaredank', 'climbingmemesofinstagram'])
self.ctx = ssl.create_default_context()
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter