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
The following causes a TypeError when attempting to access u as an Array when it's null:
at Object.urlParser (as parse) in urlparser/index.js — line 129
TypeError: Cannot read property '1' of null
Code to replicate:
var urlparser = require("urlparser");
urlparser.parse("http:")
or
var urlparser = require("urlparser");
urlparser.parse("https:")
Would suggest simply checking for null from RegEx execution and return empty object in this case. I use this to validate URLs as a user is typing them in and so it blows up as they type.
The text was updated successfully, but these errors were encountered:
The following causes a TypeError when attempting to access u as an Array when it's null:
at Object.urlParser (as parse) in urlparser/index.js — line 129
TypeError: Cannot read property '1' of null
Code to replicate:
or
Would suggest simply checking for null from RegEx execution and return empty object in this case. I use this to validate URLs as a user is typing them in and so it blows up as they type.
The text was updated successfully, but these errors were encountered: