mirror of
https://github.com/RYGhub/royalnet.git
synced 2024-11-23 19:44:20 +00:00
magari stavolta è quella buona
This commit is contained in:
parent
69e888d36d
commit
1b1c88fd65
1 changed files with 3 additions and 0 deletions
3
bot.py
3
bot.py
|
@ -472,6 +472,7 @@ def lolfree():
|
|||
def getrygimage():
|
||||
# Ricevi il link alla tua immagine del profilo Royal Games.
|
||||
print("@" + username + ": /getrygimage")
|
||||
cmd = text.split(" ", 1)
|
||||
if len(cmd) > 1:
|
||||
if len(cmd[1]) > 2:
|
||||
telegram.sendmessage("Puoi mettere solo due lettere.")
|
||||
|
@ -479,7 +480,9 @@ def getrygimage():
|
|||
# FIXME: percorsi assoluti
|
||||
directory = "/var/www/html/rygimages/{}.png"
|
||||
infile = open("/royal/bot/basiclogo.svg", "r")
|
||||
print(infile.read())
|
||||
indata = infile.read().format(cmd[1]).encode()
|
||||
print(indata.decode())
|
||||
infile.close()
|
||||
try:
|
||||
outfile = open(directory.format(cmd[1]), "x")
|
||||
|
|
Loading…
Reference in a new issue