Skip to content
Snippets Groups Projects

Resolve "Internal Changes representation is not working as expected"

1 file
+ 9
1
Compare changes
  • Side-by-side
  • Inline
+ 9
1
@@ -141,7 +141,15 @@ func stateManager(ch *Change, timeout time.Duration) (chan<- ppb.Change_State, <
if ch.state == ppb.Change_CONFIRMED {
continue
}
err := ch.callback(ch.intendedState, ch.previousState)
//TODO: debug -> remove
ch.lock.Lock()
intendedStateCopy := ch.intendedState
previousStateStateCopy := ch.previousState
ch.lock.Unlock()
// END
err := ch.callback(intendedStateCopy, previousStateStateCopy)
if err != nil {
ch.lock.Lock()
ch.state = ppb.Change_INCONSISTENT
Loading