Skip to content

Commit

Permalink
support buy(hex)
Browse files Browse the repository at this point in the history
  • Loading branch information
mafintosh committed Feb 1, 2021
1 parent c531fd4 commit d4d0ef9
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions market.js
Expand Up @@ -168,6 +168,10 @@ class Market extends EventEmitter {
}

buy (seller, opts) {
if (typeof seller === 'string') {
seller = Buffer.from(seller, 'hex')
}

// support for dazaar cards
if (!Buffer.isBuffer(seller)) {
seller = Buffer.from(seller.id, 'hex')
Expand Down

0 comments on commit d4d0ef9

Please sign in to comment.