Merge pull request #1387 from lavalamp/fix4

Don't pass empty labels (looks weird to POST with a label set)
pull/6/head
Clayton Coleman 2014-09-22 16:41:01 -04:00
commit b9028753b0
1 changed files with 4 additions and 3 deletions

View File

@ -304,9 +304,10 @@ func executeAPIRequest(method string, c *client.Client) bool {
return false
}
r := c.Verb(verb).
Path(path).
ParseSelectorParam("labels", *selector)
r := c.Verb(verb).Path(path)
if len(*selector) > 0 {
r.ParseSelectorParam("labels", *selector)
}
if setBody {
if version != 0 {
data := readConfig(storage, c.RESTClient.Codec)