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