From 12c4e1f61c49cd4e625a62e9bde7df9e02c0c47c Mon Sep 17 00:00:00 2001 From: Otter Bot Society <76196097+OtterBotSociety@users.noreply.github.com> Date: Mon, 8 Sep 2025 23:48:16 -0700 Subject: [PATCH] Treat images with no exif metadata as well-oriented (#6006) --- pkg/file/image/orientation.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/file/image/orientation.go b/pkg/file/image/orientation.go index 84f5774cf..0d9ebb2e3 100644 --- a/pkg/file/image/orientation.go +++ b/pkg/file/image/orientation.go @@ -4,6 +4,7 @@ import ( "errors" "fmt" "io" + "strings" "github.com/rwcarlsen/goexif/exif" "github.com/stashapp/stash/pkg/logger" @@ -33,7 +34,7 @@ func areDimensionsFlipped(fs models.FS, path string) (bool, error) { x, err := exif.Decode(r) if err != nil { - if errors.Is(err, io.EOF) { + if errors.Is(err, io.EOF) || strings.Contains(err.Error(), "failed to find exif") { // no exif data return false, nil }