Storage: fix svg upload (#52395)

pull/50796/head^2
Artur Wierzbicki 3 years ago committed by GitHub
parent 076851313d
commit 67ea2da57e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      pkg/services/store/http.go

@ -110,7 +110,7 @@ func (s *httpStorage) Upload(c *models.ReqContext) response.Response {
entityType := EntityTypeJSON
mimeType := http.DetectContentType(data)
if strings.HasPrefix(mimeType, "image") {
if strings.HasPrefix(mimeType, "image") || strings.HasSuffix(path, ".svg") {
entityType = EntityTypeImage
}

Loading…
Cancel
Save