| Current Path : /usr/local/lib/node_modules/@google/gemini-cli/node_modules/es-toolkit/dist/function/ |
| Current File : //usr/local/lib/node_modules/@google/gemini-cli/node_modules/es-toolkit/dist/function/once.mjs |
function once(func) {
let called = false;
let cache;
return function (...args) {
if (!called) {
called = true;
cache = func(...args);
}
return cache;
};
}
export { once };