mirror of
https://github.com/yasirarism/MissKatyPyro.git
synced 2026-01-05 03:34:51 +00:00
Hmm
This commit is contained in:
parent
13f5847505
commit
eb73e7a50b
1 changed files with 0 additions and 22 deletions
|
|
@ -37,33 +37,11 @@ async def edit_or_reply(msg, **kwargs):
|
||||||
async def log_file(bot, message):
|
async def log_file(bot, message):
|
||||||
"""Send log file"""
|
"""Send log file"""
|
||||||
try:
|
try:
|
||||||
try:
|
|
||||||
text_file = open("MissKatyLogs.txt", "r")
|
|
||||||
data = text_file.read()
|
|
||||||
json_data = {
|
|
||||||
"content": data,
|
|
||||||
"highlighting_language": "auto",
|
|
||||||
"ephemeral": False,
|
|
||||||
"expire_at": 0,
|
|
||||||
"expire_in": 0,
|
|
||||||
}
|
|
||||||
response = await http.post("https://paste.yasir.eu.org/api/new", json=json_data)
|
|
||||||
link = f"https://paste.yasir.eu.org/{response.json()['id']}"
|
|
||||||
LOGGER.info(link)
|
|
||||||
text_file.close()
|
|
||||||
except:
|
|
||||||
link = None
|
|
||||||
await message.reply_document(
|
await message.reply_document(
|
||||||
"MissKatyLogs.txt",
|
"MissKatyLogs.txt",
|
||||||
caption="Log Bot MissKatyPyro",
|
caption="Log Bot MissKatyPyro",
|
||||||
reply_markup=InlineKeyboardMarkup(
|
reply_markup=InlineKeyboardMarkup(
|
||||||
[
|
[
|
||||||
[
|
|
||||||
InlineKeyboardButton(
|
|
||||||
"🌀 Open in Web",
|
|
||||||
link,
|
|
||||||
)
|
|
||||||
],
|
|
||||||
[
|
[
|
||||||
InlineKeyboardButton(
|
InlineKeyboardButton(
|
||||||
"❌ Close",
|
"❌ Close",
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue