Issues (2)

src/checker.js (1 issue)

Labels
Severity
1
import 'isomorphic-fetch';
2
import fetch from 'node-fetch';
3
4
export const isFetchResponseError = e =>
5
	e instanceof fetch.Response || e instanceof Response;
0 ignored issues
show
The variable Response seems to be never declared. If this is a global, consider adding a /** global: Response */ comment.

This checks looks for references to variables that have not been declared. This is most likey a typographical error or a variable has been renamed.

To learn more about declaring variables in Javascript, see the MDN.

Loading history...
6
7
export const isFetchNetworkError = e => e instanceof fetch.FetchError;
8
9
export const isFetchError = e =>
10
	isFetchResponseError(e) || isFetchNetworkError(e);
11