From 8fa6e2b103e436435ad0f0ae00e8cc9af4c58ad4 Mon Sep 17 00:00:00 2001 From: Victor Vieux Date: Wed, 30 Oct 2013 11:24:50 -0700 Subject: [PATCH] improve error message --- runtime.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/runtime.go b/runtime.go index 097a74a1f4..0834dd668a 100644 --- a/runtime.go +++ b/runtime.go @@ -355,6 +355,9 @@ func (runtime *Runtime) Create(config *Config, name string) (*Container, []strin // Set the enitity in the graph using the default name specified if _, err := runtime.containerGraph.Set(name, id); err != nil { + if strings.HasSuffix(err.Error(), "name are not unique") { + return nil, nil, fmt.Errorf("Conflict, %s already exists.", name) + } return nil, nil, err }