mirror of https://github.com/kurisufriend/frontend
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
411 B
17 lines
411 B
function get_instance() {
|
|
var addr = "test.cynic.moe";
|
|
var cookie = document.cookie;
|
|
if(cookie != "") {
|
|
addr = decodeURIComponent(cookie).split(";")[0].split("=")[1];
|
|
}
|
|
return addr;
|
|
}
|
|
|
|
function set_instance(addr) {
|
|
var str = "Instance="+addr+"; SameSite=Lax;";
|
|
document.cookie = str;
|
|
}
|
|
|
|
function clear_instance() {
|
|
document.cookie = "Instance=test.cynic.moe; SameSite=Lax;";
|
|
}
|
|
|