Skip to content

Conversation

fb55
Copy link

@fb55 fb55 commented Oct 30, 2016

This ensures authentication options are passed to these requests.

Fixes #1318

This ensures authentication options are passed to these requests.

fixes #1318
getRegistry(packageName: string): string {
// If this is a request for a file, return the registry from the URL
if (HTTPS_EXPRESSION.test(packageName)) {
const registryProtocolHost = packageName.match(/^https?:\/\/[^\/]+\//i);
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This only matches on the protocol + hostname. An npm registry URL can also include a path, e.g. for registries that are part of a larger artifact hosting application, like Nexus or Artifactory.

@bestander
Copy link
Member

Thanks for the PR, the case is covered in a bit more generic way in #1666.
So I'll close this one

@bestander bestander closed this Nov 14, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants