helper/resource: destroy on requiresNew

pull/5/head
Mitchell Hashimoto 12 years ago
parent 5384f63b3d
commit b6a02e473d

@ -23,7 +23,7 @@ func (m *Map) Apply(
return nil, fmt.Errorf("Unknown resource type: %s", s.Type)
}
if d.Destroy {
if d.Destroy || d.RequiresNew() {
if s.ID != "" {
// Destroy the resource if it is created
err := r.Destroy(s, meta)

Loading…
Cancel
Save