Skip to content

Commit

Permalink
config/dell.go: Marshal XML/JSON from SystemConfiguration not dellConfig
Browse files Browse the repository at this point in the history
  • Loading branch information
splaspood committed Mar 18, 2024
1 parent 5049267 commit 40e776a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions config/dell.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,14 +102,14 @@ func (cm *dellVendorConfig) Raw(name, value string, menuPath []string) {
func (cm *dellVendorConfig) Marshal() (string, error) {
switch strings.ToLower(cm.ConfigFormat) {
case "xml":
x, err := xml.Marshal(cm.ConfigData)
x, err := xml.Marshal(cm.ConfigData.SystemConfiguration)
if err != nil {
return "", err
}

return string(x), nil
case "json":
x, err := json.Marshal(cm.ConfigData)
x, err := json.Marshal(cm.ConfigData.SystemConfiguration)
if err != nil {
return "", err
}
Expand Down

0 comments on commit 40e776a

Please sign in to comment.