MCPcopy Index your code
hub / github.com/angular/angular / onError

Method onError

packages/common/http/src/jsonp.ts:250–262  ·  view source on GitHub ↗
(error: Error)

Source from the content-addressed store, hash-verified

248 // a Javascript error. It emits the error via the Observable error channel as
249 // a HttpErrorResponse.
250 const onError = (error: Error) => {
251 cleanup();
252
253 // Wrap the error in a HttpErrorResponse.
254 observer.error(
255 new HttpErrorResponse({
256 error,
257 status: 0,
258 statusText: 'JSONP Error',
259 url,
260 }),
261 );
262 };
263
264 // Subscribe to both the success (load) and error events on the <script> tag,
265 // and add it to the page.

Callers 1

validateAsyncFunction · 0.80

Calls 2

errorMethod · 0.65
cleanupFunction · 0.50

Tested by

no test coverage detected