Skip to content

Commit

Permalink
Closes Mosuswalks#2: Get CVV not CV_CODE from .env file
Browse files Browse the repository at this point in the history
As described in Mosuswalks#2, the README tells the user to create a `.env` file
with a `CVC` variable in it but the `bot.js` file references a `CV_CODE`
variable in the dotenv file which doesn't exists. It's actually called a
Card Verification Value (CVV) code and not a CVC code and hence the
variable names were adjusted to match that.
  • Loading branch information
markf94 committed Jan 8, 2021
1 parent 4c22d3e commit 1d3dafb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ npm install
```sh
[email protected]
PASS=yournikeaccountpassword
CVC=yourcreditcardcvc
CVV=yourcreditcardcvv
```

2. In the bot.js file, edit the following lines.
Expand Down
6 changes: 3 additions & 3 deletions bot.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ const runSnkrBot = () => {
const email = process.env.EMAIL;
const pass = process.env.PASS;

// cv_code: 3-digit credit card validation code for the card saved to your Nike.com account
const cv_code = process.env.CV_CODE
// cvv_code: 3-digit credit card validation value for the card saved to your Nike.com account
const cvv_code = process.env.CVV

// size: the shoe size, as you see in the table of sizes on a product page, e.g., 'M 9 / W 10.5'
const size = 'US M 9.5 / W 11';
Expand Down Expand Up @@ -273,7 +273,7 @@ const runSnkrBot = () => {
() => (document.getElementById("cvNumber").focus())
);
await target_frame.waitFor(1000);
await page.keyboard.type(cv_code, {delay: 10});
await page.keyboard.type(cvv_code, {delay: 10});


//#### LOG / DEBUG
Expand Down

0 comments on commit 1d3dafb

Please sign in to comment.