You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: index.js
+19-40Lines changed: 19 additions & 40 deletions
Original file line number
Diff line number
Diff line change
@@ -12,43 +12,25 @@ const storage = new Storage({
12
12
keyFilename: config.keys.cloud_storage.path
13
13
});
14
14
15
-
functionparseURL(urlString){
16
-
try{
17
-
returnurl.parse(urlString);
18
-
}
19
-
catch(e){
20
-
// TODO
21
-
}
22
-
}
23
-
24
-
functioncheckURLStatus(url){
15
+
/**
16
+
* verifyURL - confirm that the URL can be reached.
17
+
* @param {string} url
18
+
* @return {Promise} Promise resolves to the url or rejects with a JSON object as error.
19
+
*
20
+
* TODO: Add in more specific error messages for rejection and parsing errors:: {url, error:'invalidURL', message:'URL could not be parsed. Please check that URL is valid'}
0 commit comments