Vehicle: fix validation

This commit is contained in:
andig 2026-02-01 17:34:39 +01:00
parent 21747236d0
commit a6f17db502

View file

@ -141,7 +141,7 @@ func NewConfigurableFromConfig(ctx context.Context, other map[string]any) (api.V
}
switch {
case getMaxCurrent == nil && maxCurrent != nil:
case maxCurrent == nil && getMaxCurrent != nil:
return nil, errors.New("cannot have current without current control")
case status == nil && maxCurrent != nil:
return nil, errors.New("cannot have current control without status")