diff --git a/src/View/Results/CustomPlot/Plot.py b/src/View/Results/CustomPlot/Plot.py
index 41d1652db5d8b075655c52723f7f750c3b132e37..28ae310c8e2644ff00ff6ff26919ada2853b6c24 100644
--- a/src/View/Results/CustomPlot/Plot.py
+++ b/src/View/Results/CustomPlot/Plot.py
@@ -641,7 +641,7 @@ class CustomPlot(PamhyrPlot):
         )
         if "bed_elevation" in self._y:
             if self._current_res_id != 2:
-                self.lines["bed_elevation"][0].set_ydata(z_min)
+                dz = z_min
             else:
                 if reach.has_sediment():
                     z_min1 = self.draw_bottom_with_bedload(reach1)