Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error with a node steam bot #13433

Closed
LEIDERPRO opened this issue Jun 3, 2017 · 3 comments
Closed

Error with a node steam bot #13433

LEIDERPRO opened this issue Jun 3, 2017 · 3 comments

Comments

@LEIDERPRO
Copy link

Hello i am new in nodejs and i have the following error:

` "twoFactorJSON": twofactorAuth
^^^^^^^^^^^^^^^

SyntaxError: Unexpected string
at createScript (vm.js:74:10)
at Object.runInThisContext (vm.js:116:10)
at Module._compile (module.js:533:28)
at Object.Module._extensions..js (module.js:580:10)
at Module.load (module.js:503:32)
at tryModuleLoad (module.js:466:12)
at Function.Module._load (module.js:458:3)
at Function.Module.runMain (module.js:605:10)
at startup (bootstrap_node.js:158:16)
at bootstrap_node.js:575:3
`

in app.js line 133-147

`var twofactorAuth;
if (fs.existsSync('twofactor.json')) {
twofactorAuth = JSON.parse(fs.readFileSync('twofactor.json'));
}

// Steam logon options
var logOnOptions = {
"accountName": configs.steam.user,
"password": configs.steam.password,
"twoFactorCode": SteamTotp.getAuthCode(twofactorAuth["shared_secret"])
"twoFactorJSON": twofactorAuth
};
`

@addaleax
Copy link
Member

addaleax commented Jun 3, 2017

You forgot a , after the twoFactorCode line. ;)

Just so you know, https://github.com/nodejs/help is generally a better repository for this kind of question, so unless you think something is a bug in Node itself, that’s the place to go.

@LEIDERPRO
Copy link
Author

oh oky thanks you :)

@addaleax
Copy link
Member

addaleax commented Jun 3, 2017

Cool, I’m closing this as an answered question then

@addaleax addaleax closed this as completed Jun 3, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants