Exemple #1
0
 api.checkLogin(req, function(err) {
     if (err) return api.sendJSON(req, err);
     api.handleSessionSignature(req, () => {
         req.options.cleanup = api.authTable;
         api.sendJSON(req, err, req.account);
     });
 });
Exemple #2
0
 this.app.all("/logout", function(req, res) {
     api.clearSessionSignature(req);
     api.sendJSON(req);
 });
Exemple #3
0
 api.handleSessionSignature(req, () => {
     req.options.cleanup = api.authTable;
     api.sendJSON(req, err, req.account);
 });
Exemple #4
0
 this.app.all("/ping", function(req, res) {
     api.sendJSON(req, null, {});
 });