Skip to content
Snippets Groups Projects
Commit a09475d2 authored by Rhys Arkins's avatar Rhys Arkins
Browse files

fix(docker): match https prefix

parent 7f47d457
No related branches found
No related tags found
No related merge requests found
......@@ -19,7 +19,7 @@ function massageRegistry(input, registryUrls) {
if (!registry || registry === 'docker.io') {
registry = 'index.docker.io';
}
if (!registry.match('$https?://')) {
if (!registry.match('^https?://')) {
registry = `https://${registry}`;
}
return registry;
......
......@@ -193,13 +193,13 @@ exports[`api/docker getPkgReleases uses custom registry 1`] = `
[MockFunction] {
"calls": Array [
Array [
"https://https://registry.company.com/v2/",
"https://registry.company.com/v2/",
Object {
"throwHttpErrors": false,
},
],
Array [
"https://https://registry.company.com/v2/library/node/tags/list?n=10000",
"https://registry.company.com/v2/library/node/tags/list?n=10000",
Object {
"headers": Object {},
"json": true,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment