mirror of
https://github.com/HeyPuter/puter.git
synced 2025-01-23 14:20:22 +08:00
chore: Clarify usage of window fields in UIWindowSaveAccount.js
/puter/src/UI/UIWindowSaveAccount.js 130:22 error 'api_origin' is not defined no-undef 142:48 error 'auth_token' is not defined no-undef 145:21 error 'update_auth_data' is not defined no-undef
This commit is contained in:
parent
e5d4be6250
commit
66cdf98190
@ -127,7 +127,7 @@ async function UIWindowSaveAccount(options){
|
||||
$(el_window).find('.signup-btn').prop('disabled', true);
|
||||
|
||||
$.ajax({
|
||||
url: api_origin + "/save_account",
|
||||
url: window.api_origin + "/save_account",
|
||||
type: 'POST',
|
||||
async: true,
|
||||
contentType: "application/json",
|
||||
@ -139,10 +139,10 @@ async function UIWindowSaveAccount(options){
|
||||
send_confirmation_code: options.send_confirmation_code,
|
||||
}),
|
||||
headers: {
|
||||
"Authorization": "Bearer "+auth_token
|
||||
"Authorization": "Bearer "+window.auth_token
|
||||
},
|
||||
success: async function (data){
|
||||
update_auth_data(data.token, data.user)
|
||||
success: async function (data){
|
||||
window.update_auth_data(data.token, data.user)
|
||||
|
||||
//close this window
|
||||
if(data.user.email_confirmation_required){
|
||||
|
Loading…
Reference in New Issue
Block a user