mirror of
https://github.com/luscis/openlan.git
synced 2025-12-24 11:10:54 +08:00
fix: cert not update
This commit is contained in:
@@ -153,12 +153,13 @@ func (s *Switch) Format() {
|
||||
for _, obj := range s.Network {
|
||||
context := obj.Specifies
|
||||
obj.NewSpecifies()
|
||||
if data, err := libol.Marshal(context, true); err == nil {
|
||||
if err := libol.Unmarshal(obj.Specifies, data); err != nil {
|
||||
libol.Warn("Switch.Format %s", err)
|
||||
} else {
|
||||
libol.Info("Switch.Format %v", obj.Specifies)
|
||||
}
|
||||
if obj.Specifies == nil {
|
||||
continue
|
||||
}
|
||||
if data, err := libol.Marshal(context, true); err != nil {
|
||||
libol.Warn("Switch.Format %s", err)
|
||||
} else if err := libol.Unmarshal(obj.Specifies, data); err != nil {
|
||||
libol.Warn("Switch.Format %s", err)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user