server/lib/account/index.js
//TODO: need better method to generate tokens
need better method to generate tokens
need better method to generate tokens
function registerAccount() {
    var account = new Account({
      username: req.body.username,
      email: req.body.email,
      directemail: "",
      verified: false,
      token: randomToken
    });
    Account.register(account, req.body.password, function(err, account) {
      if (err) {
        throw (err);
      }
      res.send(200);
    });
  }
function registerAccount ( ) { var account = new Account ( { username : req . body . username , email : req . body . email , directemail : "" , verified : false , token : randomToken } ) ; Account . register ( account , req . body . password , function ( err , account ) { if ( err ) { throw ( err ) ; } res . send ( 200 ) ; } ) ; }
TODO: need better method to generate tokens
TODO : need better method to generate tokens