Skip to content
Snippets Groups Projects
Verified Commit ee97327c authored by Jonathan Weth's avatar Jonathan Weth :keyboard:
Browse files

Add support for serving media files with runserver

parent 1e288147
No related branches found
No related tags found
No related merge requests found
......@@ -44,6 +44,9 @@ urlpatterns = [
# collectstatic is also required in development for this
urlpatterns += static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
# Serve media files from MEDIA_ROOT to make it work with runserver
urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
# Add URLs for optional features
if hasattr(settings, "TWILIO_ACCOUNT_SID"):
from two_factor.gateways.twilio.urls import urlpatterns as tf_twilio_urls # noqa
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment