jezdez / django-staticfiles

[Unmaintained] A Django app that provides helpers for serving static files, used in Django and Pinax.

Home Page:http://django-staticfiles.readthedocs.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Apps without models are ignored

vanschelven opened this issue · comments

Django-staticfiles' codebase makes use of models.get_apps() in two locations. This method only returns those apps which have models (not just models.py, but one or more actual model definitions).

In some cases, I may want to override an app's media, without providing new models.

I have provided two patches (sorry for bitbucket, google led me there first). I will not be offended if you find a more elegant solution (perhaps using an existing Django method?)

https://bitbucket.org/vanschelven/django-staticfiles/changeset/645a024c1760
https://bitbucket.org/vanschelven/django-staticfiles/changeset/bb5c7738d779

Klaas

FYI, I've fixed this in Django trunk (http://code.djangoproject.com/changeset/15219) and will backport this soon here.