From 5bc580da731484f716f79b0be33ecb4a33032de3 Mon Sep 17 00:00:00 2001 From: Rebecca Turner Date: Fri, 6 Jul 2018 18:01:30 -0700 Subject: [PATCH] fix(index): Guard against non-string types --- index.js | 1 + 1 file changed, 1 insertion(+) diff --git a/index.js b/index.js index f90afdc..c1c2cc8 100644 --- a/index.js +++ b/index.js @@ -26,6 +26,7 @@ var authProtocols = { var cache = {} module.exports.fromUrl = function (giturl, opts) { + if (typeof giturl !== 'string') return var key = giturl + JSON.stringify(opts || {}) if (!(key in cache)) {