mirror of
https://github.com/akvorado/akvorado.git
synced 2025-12-11 22:14:02 +01:00
build: bump github.com/gin-gonic/gin from 1.9.1 to 1.10.0
Also update YAML MIME type.
This commit is contained in:
committed by
Vincent Bernat
parent
fcb3c9f1e1
commit
17d9a6b6de
@@ -56,7 +56,7 @@ func (c ConfigRelatedOptions) Parse(out io.Writer, component string, config inte
|
||||
defer resp.Body.Close()
|
||||
contentType := resp.Header.Get("Content-Type")
|
||||
mediaType, _, err := mime.ParseMediaType(contentType)
|
||||
if mediaType != "application/x-yaml" || err != nil {
|
||||
if (mediaType != "application/x-yaml" && mediaType != "application/yaml") || err != nil {
|
||||
return fmt.Errorf("received configuration file is not YAML (%s)", contentType)
|
||||
}
|
||||
input, err := io.ReadAll(resp.Body)
|
||||
|
||||
Reference in New Issue
Block a user