PHP 7.4.33
Preview: reusify.js Size: 454 B
/var/www/sitesecurity.bitkit.dk/httpdocs/node_modules/reusify/reusify.js
'use strict'

function reusify (Constructor) {
  var head = new Constructor()
  var tail = head

  function get () {
    var current = head

    if (current.next) {
      head = current.next
    } else {
      head = new Constructor()
      tail = head
    }

    current.next = null

    return current
  }

  function release (obj) {
    tail.next = obj
    tail = obj
  }

  return {
    get: get,
    release: release
  }
}

module.exports = reusify

Directory Contents

Dirs: 1 × Files: 7
Name Size Perms Modified Actions
- drwxr-xr-x 2026-04-28 09:11:39
Edit Download
46 B lrw-r--r-- 2026-04-28 09:11:39
Edit Download
284 B lrw-r--r-- 2026-04-28 09:11:39
Edit Download
1.06 KB lrw-r--r-- 2026-04-28 09:11:39
Edit Download
1023 B lrw-r--r-- 2026-04-28 09:11:39
Edit Download
3.55 KB lrw-r--r-- 2026-04-28 09:11:39
Edit Download
454 B lrw-r--r-- 2026-04-28 09:11:39
Edit Download
1.41 KB lrw-r--r-- 2026-04-28 09:11:39
Edit Download
If ZipArchive is unavailable, a .tar will be created (no compression).