hosted-git-info
Advanced tools
Comparing version 2.3.0 to 2.3.1
@@ -32,3 +32,3 @@ 'use strict' | ||
var parsed = parseGitUrl(url) | ||
var shortcutMatch = url.match(new RegExp('^([^:]+):([^/]+)[/](.+)$')) | ||
var shortcutMatch = url.match(new RegExp('^([^:]+):(?:(?:[^@:]+(?:[^@]+)?@)?([^/]*))[/](.+?)(?:[.]git)?($|#)')) | ||
var matches = Object.keys(gitHosts).map(function (gitHostName) { | ||
@@ -46,3 +46,3 @@ try { | ||
if (shortcutMatch && shortcutMatch[1] === gitHostName) { | ||
user = decodeURIComponent(shortcutMatch[2]) | ||
user = shortcutMatch[2] && decodeURIComponent(shortcutMatch[2]) | ||
project = decodeURIComponent(shortcutMatch[3]) | ||
@@ -49,0 +49,0 @@ defaultRepresentation = 'shortcut' |
{ | ||
"name": "hosted-git-info", | ||
"version": "2.3.0", | ||
"version": "2.3.1", | ||
"description": "Provides metadata and conversions from repository urls for Github, Bitbucket and Gitlab", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
14634