diff options
Diffstat (limited to '2666/main.js')
-rwxr-xr-x | 2666/main.js | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/2666/main.js b/2666/main.js new file mode 100755 index 0000000..8211bb7 --- /dev/null +++ b/2666/main.js @@ -0,0 +1,12 @@ +#!/usr/bin/env node +var once = function (fn) { + var called = false; + return function (...args) { + if (called) { + return undefined; + } else { + called = true; + return fn(...args); + } + }; +}; |