mirror of
https://github.com/NovaOSS/nova-cord.git
synced 2024-11-25 16:03:57 +01:00
Fixes
This commit is contained in:
parent
94a68a70f9
commit
bfd6608f39
|
@ -1,7 +1,7 @@
|
||||||
"""Account system functionality."""
|
"""Account system functionality."""
|
||||||
|
|
||||||
import os
|
import os
|
||||||
import json
|
import ujson
|
||||||
import requests
|
import requests
|
||||||
import string
|
import string
|
||||||
import random
|
import random
|
||||||
|
@ -45,7 +45,7 @@ This is all we have stored about your API account in our database.
|
||||||
Feel free to request a removal of your account by contacting the staff.
|
Feel free to request a removal of your account by contacting the staff.
|
||||||
|
|
||||||
||```json
|
||```json
|
||||||
{json.dumps(account, indent=4)}
|
{ujson.dumps(account, indent=4)}
|
||||||
```||
|
```||
|
||||||
(Click to reveal)
|
(Click to reveal)
|
||||||
|
|
||||||
|
@ -114,7 +114,7 @@ Please report this issue to the staff!""", ephemeral=True)
|
||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
'Authorization': os.getenv('CORE_API_KEY')
|
'Authorization': os.getenv('CORE_API_KEY')
|
||||||
},
|
},
|
||||||
data=json.dumps({
|
data=ujson.dumps({
|
||||||
"discord_id": account["auth"]["discord"],
|
"discord_id": account["auth"]["discord"],
|
||||||
"updates": {"$set": {"credits": amount}}
|
"updates": {"$set": {"credits": amount}}
|
||||||
})
|
})
|
||||||
|
@ -141,7 +141,7 @@ async def reset_key(interaction):
|
||||||
'Content-Type': 'application/json',
|
'Content-Type': 'application/json',
|
||||||
'Authorization': os.getenv('CORE_API_KEY')
|
'Authorization': os.getenv('CORE_API_KEY')
|
||||||
},
|
},
|
||||||
data=json.dumps({
|
data=ujson.dumps({
|
||||||
"discord_id": account["auth"]["discord"],
|
"discord_id": account["auth"]["discord"],
|
||||||
"updates": {"$set": {"api_key": await new_api_key()}}
|
"updates": {"$set": {"api_key": await new_api_key()}}
|
||||||
})
|
})
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
import embedder
|
import embedder
|
||||||
|
|
||||||
|
|
||||||
from nextcord import DMChannel
|
from nextcord import DMChannel
|
||||||
|
|
||||||
async def process(message):
|
async def process(message):
|
||||||
|
|
5
requirements.txt
Normal file
5
requirements.txt
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
openai
|
||||||
|
aiohttp
|
||||||
|
nextcord
|
||||||
|
requests
|
||||||
|
python-dotenv
|
Loading…
Reference in a new issue