check for empty diff in CountHook.PreApply
Make sure we don't try to count anything from a nil diff.
This commit is contained in:
parent
dbe9599820
commit
f8bfc0a80d
|
@ -42,6 +42,10 @@ func (h *CountHook) PreApply(
|
|||
h.Lock()
|
||||
defer h.Unlock()
|
||||
|
||||
if d.Empty() {
|
||||
return terraform.HookActionContinue, nil
|
||||
}
|
||||
|
||||
if h.pending == nil {
|
||||
h.pending = make(map[string]countHookAction)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue