Hi i using this code for login
function login(err, sessionID, cookies, steamguard) {
if(err) {
logger.error('Auth error');
logger.debug(err);
if(err.message == "SteamGuardMobile") {
account.twoFactorCode = SteamTotp.generateAuthCode(account.shared_secret);
logger.warn('Error in auth: '+account.twoFactorCode);
setTimeout(function() {
community.login(account, login);
}, 5000);
return;
}
process.exit(0);
}
logger.trace('Sucesfully auth');
account.sessionID = sessionID;
account.cookies = cookies;
community.getWebApiKey('secrect.com', webApiKey);
community.startConfirmationChecker(10000, account.identity_secret);
}
after 2 ~ 3 days i lost my session, and i use this for new loggin
community.on('sessionExpired', function(err) {
if (err) {
console.log('sessionExpired: '+err);
}
community.stopConfirmationChecker();
community.login(account, login);
console.log('=======New Session=========');
});
How I force to lose my session? for testing my code? It's horrible to have to wait 2 ~ 3 days Sorry my english...