Skip to content

Commit

Permalink
src: expose list of readers via p.readers
Browse files Browse the repository at this point in the history
  • Loading branch information
ian-axiadids authored and santigimeno committed Dec 1, 2017
1 parent c87a31d commit 5cbe1b7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,9 @@ Emitted whenever a new card reader is detected.

It frees the resources associated with this PCSCLite instance. At a low level it calls [`SCardCancel`](http://pcsclite.alioth.debian.org/pcsc-lite/node21.html) so it stops watching for new readers.

#### pcsclite.readers

An object containing all detected readers by name. Updated as readers are attached and removed.

### Class: CardReader

Expand Down
1 change: 1 addition & 0 deletions lib/pcsclite.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ module.exports = function() {

var readers = {};
var p = new PCSCLite();
p.readers = readers;
process.nextTick(function() {
p.start(function(err, data) {
if (err) {
Expand Down

0 comments on commit 5cbe1b7

Please sign in to comment.