diff --git a/controller/nucleus/principalNetworkDomain.go b/controller/nucleus/principalNetworkDomain.go index 82e00ff541f2db5331047b30aa4c16f365549dc0..66d705775cb3f1b6e485286b185253bf4cf3a86d 100644 --- a/controller/nucleus/principalNetworkDomain.go +++ b/controller/nucleus/principalNetworkDomain.go @@ -149,6 +149,9 @@ func (pnd *pndImplementation) Commit(u uuid.UUID) error { // Set all the changes within the network elements model networkElement, err := pnd.networkElementService.Get(store.Query{ID: ch.AssociatedDeviceID()}) + if err != nil { + return err + } diff, err := ygot.Diff(ch.PreviousState(), ch.IntendedState()) for _, update := range diff.GetUpdate() { opts := []ytypes.SetNodeOpt{&ytypes.InitMissingElements{}, &ytypes.TolerateJSONInconsistencies{}}