Remove call to View.Destroy() that causes errors to be logged by vCenter (#4684)

This commit is contained in:
Pontus Rydin 2018-09-12 14:06:38 -04:00 committed by Daniel Nelson
parent 9bd14b283f
commit a84ca7bcdb
1 changed files with 3 additions and 5 deletions

View File

@ -164,12 +164,10 @@ func (c *Client) close() {
// to close it multiple times.
c.closeGate.Do(func() {
ctx := context.Background()
if c.Views != nil {
c.Views.Destroy(ctx)
}
if c.Client != nil {
c.Client.Logout(ctx)
if err := c.Client.Logout(ctx); err != nil {
log.Printf("E! [input.vsphere]: Error during logout: %s", err)
}
}
})
}