From bf62324e79dd584c9bd7b58d685fdcbb0231766d Mon Sep 17 00:00:00 2001 From: yasir Date: Tue, 24 Jan 2023 11:24:58 +0700 Subject: [PATCH] Fix --- misskaty/plugins/paste.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/misskaty/plugins/paste.py b/misskaty/plugins/paste.py index 973a712e..231bb149 100644 --- a/misskaty/plugins/paste.py +++ b/misskaty/plugins/paste.py @@ -103,7 +103,7 @@ async def nekopaste(_, message): uname = message.sender_chat.title try: - x = await http.post("https://nekobin.com/api/documents", json={"content": data}) + x = (await http.post("https://nekobin.com/api/documents", json={"content": data})).json() url = f"https://nekobin.com/{x['result']['key']}" except Exception as e: await msg.edit(f"ERROR: {e}") @@ -161,7 +161,7 @@ async def spacebinn(_, message): try: siteurl = "https://spaceb.in/api/v1/documents/" - response = await http.post(siteurl, data={"content": data, "extension": 'txt'} ) + response = await http.post(siteurl, data={"content": data, "extension": 'txt'}) response = response.json() url = "https://spaceb.in/"+response['payload']['id'] except Exception as e: