Skip to content

Commit a235ff1

Browse files
authored
Merge pull request #39 from codefresh-io/CR-15973-debug
catch 302 redirects
2 parents 29c116f + 9e0fc35 commit a235ff1

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "nodegistry",
3-
"version": "1.2.3",
3+
"version": "1.2.4",
44
"description": "Docker Registry Remote API module.",
55
"main": "index.js",
66
"repository": "git@github.com:codefresh-io/nodegistry.git",

src/lib/Modem.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ exports.RegistryModem = class {
110110
});
111111
}))
112112
.then(([response, body]) => {
113-
if (response.statusCode === 307) {
113+
if ([302, 307].includes(response.statusCode)) {
114114
return this.handleRedirect(response.headers.location);
115115
}
116116
return this._promise.resolve([response, body]);

0 commit comments

Comments
 (0)