From 9b6956dbe20457617c431f7816b109947d303589 Mon Sep 17 00:00:00 2001
From: Malte Bauch <malte.bauch@stud.h-da.de>
Date: Wed, 25 Jan 2023 18:00:02 +0100
Subject: [PATCH] linter pleasing

---
 controller/nucleus/principalNetworkDomain.go | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/controller/nucleus/principalNetworkDomain.go b/controller/nucleus/principalNetworkDomain.go
index 66d705775..f2662933b 100644
--- a/controller/nucleus/principalNetworkDomain.go
+++ b/controller/nucleus/principalNetworkDomain.go
@@ -153,6 +153,9 @@ func (pnd *pndImplementation) Commit(u uuid.UUID) error {
 		return err
 	}
 	diff, err := ygot.Diff(ch.PreviousState(), ch.IntendedState())
+	if err != nil {
+		return err
+	}
 	for _, update := range diff.GetUpdate() {
 		opts := []ytypes.SetNodeOpt{&ytypes.InitMissingElements{}, &ytypes.TolerateJSONInconsistencies{}}
 		if err := ytypes.SetNode(networkElement.SBI().Schema().RootSchema(), networkElement.GetModel(), update.GetPath(), update.GetVal(), opts...); err != nil {
-- 
GitLab