mirror of
https://github.com/tobspr/shapez.io.git
synced 2024-10-27 20:34:29 +00:00
Query login token for puzzle DLC api
This commit is contained in:
parent
291614cb3c
commit
e4c1355e9c
@ -101,9 +101,15 @@ export class ClientAPI {
|
|||||||
*/
|
*/
|
||||||
apiTryLogin() {
|
apiTryLogin() {
|
||||||
if (!G_IS_STANDALONE) {
|
if (!G_IS_STANDALONE) {
|
||||||
const token = window.prompt(
|
let token = window.localStorage.getItem("dev_api_auth_token");
|
||||||
|
if (!token) {
|
||||||
|
token = window.prompt(
|
||||||
"Please enter the auth token for the puzzle DLC (If you have none, you can't login):"
|
"Please enter the auth token for the puzzle DLC (If you have none, you can't login):"
|
||||||
);
|
);
|
||||||
|
}
|
||||||
|
if (token) {
|
||||||
|
window.localStorage.setItem("dev_api_auth_token", token);
|
||||||
|
}
|
||||||
return Promise.resolve({ token });
|
return Promise.resolve({ token });
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user