mirror of
https://github.com/stashapp/stash.git
synced 2025-12-17 04:14:39 +03:00
Add grid view, image to tag (#641)
* Add grid view for tags * Add tag page * Import/export tags * Add tag name uniqueness checks * Fix styling on missing marker previews * Add trace loglevel * Add SQL trace * Add filter options for tags * Add tag sort by options * Add tag page keyboard shortcuts
This commit is contained in:
@@ -59,6 +59,12 @@ func ServeImage(image []byte, w http.ResponseWriter, r *http.Request) error {
|
||||
}
|
||||
}
|
||||
|
||||
contentType := http.DetectContentType(image)
|
||||
if contentType == "text/xml; charset=utf-8" || contentType == "text/plain; charset=utf-8" {
|
||||
contentType = "image/svg+xml"
|
||||
}
|
||||
|
||||
w.Header().Set("Content-Type", contentType)
|
||||
w.Header().Add("Etag", etag)
|
||||
_, err := w.Write(image)
|
||||
return err
|
||||
|
||||
Reference in New Issue
Block a user