Skip to content

Commit

Permalink
bugfix for when the file isn't found
Browse files Browse the repository at this point in the history
  • Loading branch information
Lacrymology committed Jun 26, 2012
1 parent 34c5c83 commit e5ae536
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions django_static/templatetags/django_static.py
Expand Up @@ -638,8 +638,9 @@ def _find_filepath_in_roots(filename):
try:
from django.contrib.staticfiles import finders
absolute_path = finders.find(filename)
root, filepath = os.path.split(absolute_path)
return absolute_path, root
if absolute_path:
root, filepath = os.path.split(absolute_path)
return absolute_path, root
except ImportError:
pass
return None, None
Expand Down

0 comments on commit e5ae536

Please sign in to comment.