REDROOM
PHP 8.2.30
Path:
Logout
Edit File
Size: 1.00 KB
Close
/home/byroehnu/.trash/node_modules11/one-time/index.js
Text
Base64
'use strict'; var name = require('fn.name'); /** * Wrap callbacks to prevent double execution. * * @param {Function} fn Function that should only be called once. * @returns {Function} A wrapped callback which prevents multiple executions. * @public */ module.exports = function one(fn) { var called = 0 , value; /** * The function that prevents double execution. * * @private */ function onetime() { if (called) return value; called = 1; value = fn.apply(this, arguments); fn = null; return value; } // // To make debugging more easy we want to use the name of the supplied // function. So when you look at the functions that are assigned to event // listeners you don't see a load of `onetime` functions but actually the // names of the functions that this module will call. // // NOTE: We cannot override the `name` property, as that is `readOnly` // property, so displayName will have to do. // onetime.displayName = name(fn); return onetime; };
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 0 × Files: 5
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
async.js
1.03 KB
lrw-r--r--
2026-02-21 00:53:18
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
index.js
1.00 KB
lrw-r--r--
2026-02-21 00:53:20
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
LICENSE
1.09 KB
lrw-r--r--
2026-02-21 00:53:22
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
package.json
734 B
lrw-r--r--
2026-02-21 00:53:18
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
README.md
2.11 KB
lrw-r--r--
2026-02-21 00:53:22
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).