Skip to content

Commit

Permalink
Update README
Browse files Browse the repository at this point in the history
  • Loading branch information
aknuds1 committed Jul 11, 2019
1 parent a03f123 commit ac53c8d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ The public key is a base64 encoded string of a protobuf containing an RSA DER bu
```JavaScript
const PeerId = require('peer-id')

PeerId.create({ bits: 1024 }, (err, id) => {
PeerId.create({ bits: 1024, keyType: 'rsa' }, (err, id) => {
if (err) { throw err }
console.log(JSON.stringify(id.toJSON(), null, 2))
})
Expand Down Expand Up @@ -128,7 +128,7 @@ The key format is detailed in [libp2p-crypto](https://github.com/libp2p/js-libp2

Generates a new Peer ID, complete with public/private keypair.

- `opts: Object`: Default: `{bits: 2048}`
- `opts: Object`: Default: `{bits: 2048, keyType: 'rsa'}`
- `callback: Function`

Calls back `callback` with `err, id`.
Expand Down

0 comments on commit ac53c8d

Please sign in to comment.