Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/nodejs/node
/ then
Function
then
test/fixtures/es-module-loaders/thenable-load-hook.mjs:4–8 ·
view source on GitHub ↗
()
Source
from the content-addressed store, hash-verified
2
let
thenAlreadyAccessed = false;
3
return
{
4
get then() {
5
if
(thenAlreadyAccessed) throw
new
Error(
'must not call'
);
6
thenAlreadyAccessed = true;
7
return
(resolve) => resolve(next(url, context));
8
}
9
};
10
}
Callers
nothing calls this directly
Calls
2
resolve
Function · 0.70
next
Function · 0.50
Tested by
no test coverage detected