forked from TrueCloudLab/distribution
Update repo normalize error message to include the name of the repo.
Signed-off-by: Chuanying Du <cydu@google.com>
This commit is contained in:
parent
2800ab0224
commit
c26fa61ec9
1 changed files with 1 additions and 2 deletions
|
@ -1,7 +1,6 @@
|
||||||
package reference
|
package reference
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"errors"
|
|
||||||
"fmt"
|
"fmt"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
|
@ -42,7 +41,7 @@ func ParseNormalizedNamed(s string) (Named, error) {
|
||||||
remoteName = remainder
|
remoteName = remainder
|
||||||
}
|
}
|
||||||
if strings.ToLower(remoteName) != remoteName {
|
if strings.ToLower(remoteName) != remoteName {
|
||||||
return nil, errors.New("invalid reference format: repository name must be lowercase")
|
return nil, fmt.Errorf("invalid reference format: repository name (%s) must be lowercase", remoteName)
|
||||||
}
|
}
|
||||||
|
|
||||||
ref, err := Parse(domain + "/" + remainder)
|
ref, err := Parse(domain + "/" + remainder)
|
||||||
|
|
Loading…
Reference in a new issue