[HN]
news
ask
show
Username:
neallindsay
About:
const lockify = f => { let lock = Promise.resolve() return (...args) => { const result = lock.then(() => f(...args)) lock = result.catch(() => {}) return result.then(v => v) } }
Joined HN:
11 years ago
Karma:
684