Moved the Debugf message in a registry to a more useful place

This commit is contained in:
Sam Alba 2013-05-04 09:22:45 -07:00 коммит произвёл shin-
Родитель b0e076f374
Коммит c9994ed0fb
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -187,8 +187,8 @@ func (graph *Graph) getRemoteTags(stdout io.Writer, registries []string, reposit
req.Header.Set("Authorization", "Token "+strings.Join(token, ", ")) req.Header.Set("Authorization", "Token "+strings.Join(token, ", "))
res, err := client.Do(req) res, err := client.Do(req)
defer res.Body.Close() defer res.Body.Close()
Debugf("Got status code %d from %s", res.StatusCode, endpoint)
if err != nil || (res.StatusCode != 200 && res.StatusCode != 404) { if err != nil || (res.StatusCode != 200 && res.StatusCode != 404) {
Debugf("Registry isn't responding: trying another registry endpoint")
continue continue
} else if res.StatusCode == 404 { } else if res.StatusCode == 404 {
return nil, fmt.Errorf("Repository not found") return nil, fmt.Errorf("Repository not found")