Anons79 Mini Shell

Directory : /home/aplikasiposinfo/www/hamrishealth.aplikasipos.info/node_modules/thunky/
Upload File :
Current File : /home/aplikasiposinfo/www/hamrishealth.aplikasipos.info/node_modules/thunky/promise.js

module.exports = thunkyp

function thunkyp (fn) {
  let running = null

  return ready

  function ready () {
    if (running) return running
    const p = fn()
    if (!(p instanceof Promise)) running = Promise.resolve(p)
    else running = p
    running.catch(onerror)
    return running
  }

  function onerror () {
    running = null
  }
}

Anons79 File Manager Version 1.0, Coded By Anons79
Email: [email protected]