MCPcopy Create free account
hub / github.com/ampproject/amphtml / rejectServicePromiseForDoc

Function rejectServicePromiseForDoc

src/service-helpers.js:123–127  ·  view source on GitHub ↗
(nodeOrDoc, id, error)

Source from the content-addressed store, hash-verified

121 * @param {*} error
122 */
123export function rejectServicePromiseForDoc(nodeOrDoc, id, error) {
124 const ampdoc = getAmpdoc(nodeOrDoc);
125 const holder = getAmpdocServiceHolder(ampdoc);
126 rejectServicePromiseInternal(holder, id, error);
127}
128
129/**
130 * Returns a service for the given id and window (a per-window singleton). Users

Callers 5

test-service.jsFile · 0.90
unsupportedServiceFunction · 0.90

Calls 3

getAmpdocFunction · 0.85
getAmpdocServiceHolderFunction · 0.85

Tested by

no test coverage detected