mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-05-27 10:44:33 +00:00
web_server: Fix locating SVG icons on production setup
Tests: - On a development setup, loading the home page and a few other pages works without errors. FreedomBox icon in the navbar (and other icons) are shown. - On a testing setup, without development mode, loading the home page and a few other pages works without errors. FreedomBox icon in the navbar (and other icons) are shown. Without the patch no page loads. Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org> Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
parent
ab8d87e71d
commit
8cd1fbc6b9
@ -210,4 +210,4 @@ def resolve_static_path(url: str) -> pathlib.Path:
|
||||
|
||||
return static_dir / '/'.join(url_parts[1:])
|
||||
|
||||
return pathlib.Path(__file__).parent.parent / 'static' / url
|
||||
return pathlib.Path(cfg.file_root) / 'static' / url
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user