I terrify myself
This commit is contained in:
3
main.py
3
main.py
@@ -8,7 +8,7 @@ def populate_webhook_lookup():
|
||||
lookup = {}
|
||||
with open("lookup.txt", "r") as file:
|
||||
for line in file:
|
||||
split_line = line.split(",")
|
||||
split_line = line.rstrip().split(",")
|
||||
lookup[split_line[0]]= split_line[1]
|
||||
return lookup
|
||||
|
||||
@@ -52,6 +52,7 @@ def convert(uuid):
|
||||
webhook = lookup.get(uuid)
|
||||
print(lookup)
|
||||
ghost_payload = request.get_json()
|
||||
print(ghost_payload)
|
||||
discord_payload = convert_ghost_to_discord(ghost_payload)
|
||||
|
||||
httpx.post(webhook, data=discord_payload)
|
||||
|
||||
Reference in New Issue
Block a user