UNPKG

apns2

Version:

Node client for connecting to Apple's Push Notification Service using the new HTTP/2 protocol with JSON web tokens.

19 lines (18 loc) 759 B
export function undici_getPoolClients(pool) { const symbols = Object.getOwnPropertySymbols(pool); const clientsSymbol = symbols.find((sym) => sym.description === "clients"); if (!clientsSymbol) { return []; } // biome-ignore lint/suspicious/noExplicitAny: necessary to access private property return pool[clientsSymbol] ?? []; } export function undici_getClientHttp2Session(client) { const symbols = Object.getOwnPropertySymbols(client); const http2SessionSymbol = symbols.find((sym) => sym.description === "http2Session"); if (!http2SessionSymbol) { return null; } // biome-ignore lint/suspicious/noExplicitAny: necessary to access private property return client[http2SessionSymbol] ?? null; }