Skip to content

Commit

Permalink
fixup! rename to invokePromiseCallback
Browse files Browse the repository at this point in the history
  • Loading branch information
MattiasBuelens committed May 1, 2024
1 parent 139fd26 commit 43c8f92
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/internal/webstreams/util.js
Original file line number Diff line number Diff line change
Expand Up @@ -176,13 +176,13 @@ function enqueueValueWithSize(controller, value, size) {

// This implements "invoke a callback function type" for callback functions that return a promise.
// See https://webidl.spec.whatwg.org/#es-invoking-callback-functions
async function ensureIsPromise(fn, thisArg, ...args) {
async function invokePromiseCallback(fn, thisArg, ...args) {
return FunctionPrototypeCall(fn, thisArg, ...args);
}

function createPromiseCallback(name, fn, thisArg) {
validateFunction(fn, name);
return (...args) => ensureIsPromise(fn, thisArg, ...args);
return (...args) => invokePromiseCallback(fn, thisArg, ...args);
}

function isPromisePending(promise) {
Expand Down Expand Up @@ -274,11 +274,11 @@ module.exports = {
copyArrayBuffer,
customInspect,
dequeueValue,
ensureIsPromise,
enqueueValueWithSize,
extractHighWaterMark,
extractSizeAlgorithm,
lazyTransfer,
invokePromiseCallback,
isBrandCheck,
isPromisePending,
isViewedArrayBufferDetached,
Expand Down

0 comments on commit 43c8f92

Please sign in to comment.