From d3814b143706b5f8e0b044e922f239a9b440aa67 Mon Sep 17 00:00:00 2001 From: Michael Geers Date: Sun, 16 Feb 2025 17:00:48 +0100 Subject: [PATCH] Sessions: fix missing loadpoint names (#18868) --- core/loadpoint.go | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/core/loadpoint.go b/core/loadpoint.go index a79713851..3f47f9fdd 100644 --- a/core/loadpoint.go +++ b/core/loadpoint.go @@ -241,6 +241,14 @@ func NewLoadpointFromConfig(log *util.Logger, settings settings.Settings, other lp.mode = api.ModeOff } + if lp.Title != "" { + lp.setTitle(lp.Title) + } + + if lp.Priority > 0 { + lp.setPriority(lp.Priority) + } + return lp, nil } @@ -280,14 +288,6 @@ func (lp *Loadpoint) restoreSettings() { return } - // from yaml - if lp.Title != "" { - lp.setTitle(lp.Title) - } - if lp.Priority > 0 { - lp.setPriority(lp.Priority) - } - // deprecated yaml properties if lp.Phases_ > 0 { lp.log.WARN.Printf("ignoring deprecated phases: %d. please configure via UI", lp.Phases_)