mirror of
https://github.com/TitanEmbeds/Titan.git
synced 2024-11-12 17:11:20 +01:00
Fix sametarget
This commit is contained in:
parent
2d5a5b5131
commit
94c5e5c91a
@ -2037,17 +2037,15 @@ var passedCookieTest = true; // If passed cross origin test
|
||||
}
|
||||
|
||||
$("#discordlogin_btn").click(function(e) {
|
||||
e.preventDefault();
|
||||
var target = "_blank";
|
||||
if (getParameterByName("sametarget") == "true") {
|
||||
target = "";
|
||||
if (getParameterByName("sametarget") != "true") {
|
||||
e.preventDefault();
|
||||
var wid = window.open($("#discordlogin_btn").attr("href"), "_blank");
|
||||
postRobot.on("setSession", { window: wid }, function(event) {
|
||||
if (!passedCookieTest) {
|
||||
session = event.data.session;
|
||||
}
|
||||
});
|
||||
}
|
||||
var wid = window.open($("#discordlogin_btn").attr("href"), target);
|
||||
postRobot.on("setSession", { window: wid }, function(event) {
|
||||
if (!passedCookieTest) {
|
||||
session = event.data.session;
|
||||
}
|
||||
});
|
||||
lock_login_fields();
|
||||
wait_for_discord_login();
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user