Comparing version 9.2.0 to 9.2.1
@@ -8,3 +8,3 @@ 'use strict'; | ||
const ret = new Set(); | ||
const {searchParams} = (new URL(url.replace(/^(\/\/|(www\.))/, 'http://$2'))); | ||
const {searchParams} = (new URL(url.replace(/^(\/\/|(www\.))/i, 'http://$2'))); | ||
@@ -21,2 +21,6 @@ for (const [, value] of searchParams) { | ||
module.exports = (text, options = {}) => { | ||
if (typeof text !== 'string') { | ||
throw new TypeError(`The \`text\` argument should be a string, got ${typeof text}`); | ||
} | ||
if (typeof options.exclude !== 'undefined' && !Array.isArray(options.exclude)) { | ||
@@ -55,3 +59,2 @@ throw new TypeError('The `exclude` option must be an array'); | ||
ret.delete(item); | ||
break; | ||
} | ||
@@ -58,0 +61,0 @@ } |
{ | ||
"name": "get-urls", | ||
"version": "9.2.0", | ||
"version": "9.2.1", | ||
"description": "Get all URLs in a string", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
6017
86