Remove double slashes from URLs before matching.
This commit is contained in:
parent
a56a5c9a10
commit
20a9c01444
|
@ -62,7 +62,7 @@ module.exports = function dissectLink(url) {
|
|||
return acc;
|
||||
}
|
||||
|
||||
const match = host.pattern.match(url);
|
||||
const match = host.pattern.match(url.replace(/(https?:\/\/)|(\/)+/g, '$1$2')); // remove double slashes
|
||||
|
||||
if(match) {
|
||||
return Object.assign(match, {
|
||||
|
|
Loading…
Reference in New Issue