diff --git a/main.go b/main.go index cfbb759698cb96a3105f20dc766becf62275a200..42dced2f0c1b8e59dd8f85b8ea31c2675d9778a0 100644 --- a/main.go +++ b/main.go @@ -95,6 +95,10 @@ func main() { if *flagXMLOutput != "" { newOPML := newOPML(opml) marshalledOPML, err := xml.MarshalIndent(newOPML, "", "\t") + if err != nil { + fmt.Println(err) + os.Exit(1) + } xmlBytes := []byte(xml.Header + string(marshalledOPML)) err = os.WriteFile(*flagXMLOutput, xmlBytes, 0o644)