doorman
v0.0.2
Published
Only allow a ID to be registered once.
Downloads
491
Readme
doorman
Only allow a ID to be registered once.
Installation
npm install doorman
Usage
var dedupe = doorman()
dedupe('1') // true
dedupe('1') // false
dedupe('2') // true
dedupe('2') // false
dedupe.list() // { '1': true, '2': true }
Loading
var dedupe = doorman({ '1': true })
dedupe('1') // false
dedupe('2') // true
dedupe('2') // false
Credits
Paul Serby follow me on twitter @serby
Licence
Licensed under the New BSD License