MCPcopy Index your code
hub / github.com/hoothin/UserScripts / corsEnabled

Function corsEnabled

DownloadAllContent/DownloadAllContent.user.js:104–114  ·  view source on GitHub ↗
(url)

Source from the content-addressed store, hash-verified

102 }
103
104 function corsEnabled(url) {
105 var xhr = new XMLHttpRequest();
106
107 xhr.open('HEAD', url, false);
108
109 try {
110 xhr.send();
111 } catch (e) {}
112
113 return xhr.status >= 200 && xhr.status <= 299;
114 }
115
116
117 function click(node) {

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected