diff --git a/config/notification.go b/config/notification.go index 0e21745..d534a6a 100644 --- a/config/notification.go +++ b/config/notification.go @@ -7,7 +7,7 @@ import ( "strings" ) -func (c *NotificationType) MarshalJSON() ([]byte, error) { +func (c NotificationType) MarshalJSON() ([]byte, error) { return json.Marshal(c.Value) } diff --git a/config/save.go b/config/save.go index b3ef125..78e753d 100644 --- a/config/save.go +++ b/config/save.go @@ -9,7 +9,7 @@ import ( func Save(conf Config, filePath string) error { // Marshal config - configBytes, err := yaml.Marshal(conf) + configBytes, err := yaml.MarshalWithOptions(conf, yaml.UseJSONMarshaler()) if err != nil { return fmt.Errorf("error marshaling config: %w", err) }