mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Merge pull request #13685 from yuchangchun1/tag_regx
add a more accurate error description for invalid tag name
This commit is contained in:
commit
ba9db62e68
1 changed files with 1 additions and 1 deletions
|
@ -18,7 +18,7 @@ func ValidateTagName(name string) error {
|
|||
return fmt.Errorf("tag name can't be empty")
|
||||
}
|
||||
if !validTagName.MatchString(name) {
|
||||
return fmt.Errorf("Illegal tag name (%s): only [A-Za-z0-9_.-] are allowed, minimum 1, maximum 128 in length", name)
|
||||
return fmt.Errorf("Illegal tag name (%s): only [A-Za-z0-9_.-] are allowed ('.' and '-' are NOT allowed in the initial), minimum 1, maximum 128 in length", name)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue