mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Removing the endpoint name restriction
Signed-off-by: Madhu Venugopal <madhu@docker.com>
This commit is contained in:
parent
2e43b58b95
commit
e5ee4ada8b
2 changed files with 1 additions and 4 deletions
|
@ -152,7 +152,7 @@ func (c *Config) ProcessOptions(options ...Option) {
|
|||
|
||||
// IsValidName validates configuration objects supported by libnetwork
|
||||
func IsValidName(name string) bool {
|
||||
if strings.TrimSpace(name) == "" || strings.Contains(name, ".") {
|
||||
if strings.TrimSpace(name) == "" {
|
||||
return false
|
||||
}
|
||||
return true
|
||||
|
|
|
@ -52,7 +52,4 @@ func TestValidName(t *testing.T) {
|
|||
if IsValidName(" ") {
|
||||
t.Fatal("Name validation succeeds for a case when it is expected to fail")
|
||||
}
|
||||
if IsValidName("name.with.dots") {
|
||||
t.Fatal("Name validation succeeds for a case when it is expected to fail")
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue