<s> from django . conf import settings <EOL> from django . conf . urls . static import static <EOL> from django . contrib . staticfiles . views import serve <EOL> urlpatterns = [ ] <EOL> def staticfiles_urlpatterns ( prefix = None ) : <EOL> """<STR_LIT>""" <EOL> if prefix is None : <EOL> prefix = settings . STATIC_URL <EOL> return static ( prefix , view = serve ) <EOL> if settings . DEBUG and not urlpatterns : <EOL> urlpatterns += staticfiles_urlpatterns ( ) </s>
