forked from varia/bots
KeyError: 'url'
This commit is contained in:
parent
a117709563
commit
0dab7a74e1
@ -232,7 +232,7 @@ class Logbot(Bot):
|
|||||||
f"To be deleted: { self.db[message.room]['messages'][key] }"
|
f"To be deleted: { self.db[message.room]['messages'][key] }"
|
||||||
)
|
)
|
||||||
if 'media' in self.db[message.room]['messages'][key]:
|
if 'media' in self.db[message.room]['messages'][key]:
|
||||||
reply = f"Deleted: { self.db[message.room]['messages'][key]['media']['url'] }"
|
reply = f"Deleted: { self.db[message.room]['messages'][key]['media']['path'] }"
|
||||||
else:
|
else:
|
||||||
reply = f"Deleted: { self.db[message.room]['messages'][key]['post'] }"
|
reply = f"Deleted: { self.db[message.room]['messages'][key]['post'] }"
|
||||||
del self.db[message.room]["messages"][key]
|
del self.db[message.room]["messages"][key]
|
||||||
|
Loading…
Reference in New Issue
Block a user