mirror of
https://github.com/S2-/securerandomstring.git
synced 2025-08-02 02:10:05 +02:00
add err to async example
This commit is contained in:
@@ -15,7 +15,7 @@ var srs = require('secure-random-string');
|
||||
var result = srs();
|
||||
|
||||
// Async
|
||||
srs(function(err,sr) {
|
||||
srs(function(err, sr) {
|
||||
console.log(sr);
|
||||
});
|
||||
|
||||
@@ -33,7 +33,7 @@ with `_`, created a valid [base64url](https://en.wikipedia.org/wiki/Base64) form
|
||||
var result = srs({length: 256, urlsafe:true});
|
||||
|
||||
// async
|
||||
srs({length: 256, urlsafe:true}, function(sr) {
|
||||
srs({length: 256, urlsafe:true}, function(err, sr) {
|
||||
console.log(sr);
|
||||
});
|
||||
```
|
||||
|
Reference in New Issue
Block a user