From 89fa25cddf3f3932b8e55bee57d0bad287fe348d Mon Sep 17 00:00:00 2001 From: morpheus65535 Date: Wed, 4 May 2022 13:23:24 -0400 Subject: [PATCH] Fixed issues while trying to serve assets. #1822 --- bazarr/main.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bazarr/main.py b/bazarr/main.py index 98165ec07..35c683e8f 100644 --- a/bazarr/main.py +++ b/bazarr/main.py @@ -120,7 +120,8 @@ def web_assets(filename): mimetypes.add_type('image/png', '.png') mimetypes.add_type('image/x-icon', '.ico') - path = os.path.join(os.path.dirname(__file__), '..', 'frontend', 'build', 'assets') + # send_from_directory needs an absolute path then we'll use realpath() here + path = os.path.realpath(os.path.join(os.path.dirname(os.path.dirname(__file__)), 'frontend', 'build', 'assets')) return send_from_directory(path, filename)