[page.noauth.register] used API instance
This commit is contained in:
parent
778984239b
commit
4203cc7629
|
@ -122,10 +122,7 @@ gs.get.register.func.register = function(){
|
||||||
if( errors )
|
if( errors )
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
/* (3) Create API instance */
|
/* (3) API bindings */
|
||||||
let api = new xhrcd('douscord-srv.xdrm.io');
|
|
||||||
|
|
||||||
/* (4) API bindings */
|
|
||||||
api.onreceive = function(_response){
|
api.onreceive = function(_response){
|
||||||
|
|
||||||
// manage error
|
// manage error
|
||||||
|
@ -140,12 +137,11 @@ gs.get.register.func.register = function(){
|
||||||
|
|
||||||
api.onclose = function(){ return gs.get.router.push('register'); };
|
api.onclose = function(){ return gs.get.router.push('register'); };
|
||||||
|
|
||||||
/* (5) API call */
|
/* (4) API call */
|
||||||
api.send({
|
api.send({
|
||||||
path: 'POST /user',
|
path: 'POST /user',
|
||||||
form: {
|
form: {
|
||||||
username: username,
|
username: username,
|
||||||
mail: mail,
|
|
||||||
password: password
|
password: password
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue