Closed PhillipMC closed 7 years ago
Hello @PhillipMC, what is your node version?
Withing a google research i found some people having the same issue with another programs/libraries and they solved by updating the node version.
Please, take a look at http://stackoverflow.com/questions/36789889/syntaxerror-use-of-const-in-strict-mode
thanks @MaikeMota I fixed it that mistake but now I have another one. My config.json is the same like before. I changed nothing except I've updated my node version with the commands of your link in stackoverflow.
this is the output of my /var/log/packtpub.log:
Hi @PhillipMC I think your config.json is false. Please delete all comments. Please try this config file and put your email and password.
Finally I achieve that the bot works fine :+1: I am very grateful. Only say if there is something who don't turn on this project and I changed my crontab after update to: /usr/bin/node to /usr/local/bin/node and I copied the config.json of the website and changed the parameters, because in a first moment I changed the template and that was the problem like say @mtuanp. Thanks again.
You're welcome @PhillipMC.
Hello this is my packtpub.log const config = require('./config.json'); ^^^^^ SyntaxError: Use of const in strict mode. at Module._compile (module.js:439:25) at Object.Module._extensions..js (module.js:474:10) at Module.load (module.js:356:32) at Function.Module._load (module.js:312:12) at Function.Module.runMain (module.js:497:10) at startup (node.js:119:16) at node.js:906:3
*And this is my config.json in my packtpub folder user and password I have put right but here I put so with '':**
{ / Choose 'telegram' or 'pushbullet' according to your favorite way of get informed / "informBy": "", / Determines if you want do download the ebook after claim/ "downloadAfterClaim": false, / Determines where you want do download the ebook after claim If this config is null, the file will be download at same directory as index.js / "outputDirectory": null, "dowloadFormat": "pdf", "packtpub": { "email": "phillipm*@**.com", "password": "**" }, "pushbullet": { "apiKey": "" }, / to use telegram, you have to create a bot first. See: https://core.telegram.org/bots#3-how-do-i-create-a-bot / "telegram": { "botToken" : "", "receiverId" : "" } }