package server import ( "mime" "go.alanpearce.eu/website/internal/log" ) var newMIMEs = map[string]string{ ".xsl": "text/xsl", } func fixupMIMETypes() { for ext, newType := range newMIMEs { if err := mime.AddExtensionType(ext, newType); err != nil { log.Error("could not update mime type", "ext", ext, "mime", newType) } } } func init() { fixupMIMETypes() }