Skip to content

Commit

Permalink
Merge pull request #763 from anderslatif/master
Browse files Browse the repository at this point in the history
Updated the examples to use the word response instead of res to avoid…
  • Loading branch information
ncb000gt committed Nov 8, 2019
2 parents 2eabaf2 + 39057dd commit bffa114
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions README.md
Expand Up @@ -125,11 +125,11 @@ Note that both techniques achieve the same end-result.

```javascript
// Load hash from your password DB.
bcrypt.compare(myPlaintextPassword, hash, function(err, res) {
// res == true
bcrypt.compare(myPlaintextPassword, hash, function(err, result) {
// result == true
});
bcrypt.compare(someOtherPlaintextPassword, hash, function(err, res) {
// res == false
bcrypt.compare(someOtherPlaintextPassword, hash, function(err, result) {
// == false
});
```

Expand All @@ -150,11 +150,11 @@ bcrypt.hash(myPlaintextPassword, saltRounds).then(function(hash) {
```
```javascript
// Load hash from your password DB.
bcrypt.compare(myPlaintextPassword, hash).then(function(res) {
// res == true
bcrypt.compare(myPlaintextPassword, hash).then(function(result) {
// result == true
});
bcrypt.compare(someOtherPlaintextPassword, hash).then(function(res) {
// res == false
bcrypt.compare(someOtherPlaintextPassword, hash).then(function(result) {
// result == false
});
```

Expand Down

0 comments on commit bffa114

Please sign in to comment.