How to use the happn-wrapper.HappnWrapper function in happn-wrapper

To help you get started, we’ve selected a few happn-wrapper examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github hfreire / get-me-a-date / src / channels / happn.js View on Github external
constructor (options = {}) {
    super('happn')

    this._options = _.defaults(options, defaultOptions)

    this._happn = new HappnWrapper()

    Health.addCheck(this.name, () => new Promise((resolve, reject) => {
      if (this._happn.circuitBreaker.isOpen()) {
        return reject(new Error(`circuit breaker is open`))
      } else {
        return resolve()
      }
    }))
  }

happn-wrapper

A Happn wrapper library

MIT
Latest version published 3 years ago

Package Health Score

39 / 100
Full package analysis

Popular happn-wrapper functions

Similar packages