Don't abort when encountering invalid URLs

This commit is contained in:
Christian Muehlhaeuser
2019-12-30 06:52:33 +01:00
parent 2023fdc9f6
commit bf9cf1e06f
+1 -2
View File
@@ -2,7 +2,6 @@ package ansi
import (
"io"
"log"
"net/url"
"strings"
@@ -147,7 +146,7 @@ func isChild(node ast.Node) bool {
func resolveRelativeURL(baseURL string, rel string) string {
u, err := url.Parse(rel)
if err != nil {
log.Fatal(err)
return rel
}
if u.IsAbs() {
return rel