Skip to content

Commit

Permalink
Add comment for is_file
Browse files Browse the repository at this point in the history
Co-authored-by: Nathan Swain <swainn@users.noreply.github.com>
  • Loading branch information
araglu and swainn authored Dec 30, 2024
1 parent 1e246d6 commit 4b19891
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions tethys_apps/templatetags/site_settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ def load_custom_css(var):
var = var.lstrip("/")

try:
# Check if var is a path to a file, if so return a link tag to the file
if (Path(settings.STATIC_ROOT) / var).is_file() or static_finder.find(var):
return f'<link href="/static/{var}" rel="stylesheet" />'

Expand Down

0 comments on commit 4b19891

Please sign in to comment.