diff options
| author | Aymeric Augustin | 2013-11-24 17:30:26 +0100 |
|---|---|---|
| committer | Aymeric Augustin | 2013-11-24 17:30:26 +0100 |
| commit | 3d72c1fa927f129b2a79ea3496cce3262516705b (patch) | |
| tree | a79b175c47b00f781f2004f23271ee89cf0ee2ba /debug_toolbar/models.py | |
| parent | f52f266c691fd8bb80b21ab2a983118b914c04fa (diff) | |
| download | django-debug-toolbar-3d72c1fa927f129b2a79ea3496cce3262516705b.tar.bz2 | |
Compatibility with Django 1.7.
Diffstat (limited to 'debug_toolbar/models.py')
| -rw-r--r-- | debug_toolbar/models.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/debug_toolbar/models.py b/debug_toolbar/models.py index eba7028..2db10b8 100644 --- a/debug_toolbar/models.py +++ b/debug_toolbar/models.py @@ -2,8 +2,7 @@ from __future__ import absolute_import, unicode_literals from django.conf import settings from django.conf.urls import include, patterns, url -from django.core.urlresolvers import ( - reverse, NoReverseMatch, _resolver_cache, _ns_resolver_cache) +from django.core.urlresolvers import clear_url_caches, reverse, NoReverseMatch from django.utils.importlib import import_module import debug_toolbar @@ -54,8 +53,7 @@ def patch_root_urlconf(): urlconf_module.urlpatterns += patterns('', # noqa url(r'^__debug__/', include(debug_toolbar.urls)), ) - _resolver_cache.clear() - _ns_resolver_cache.clear() + clear_url_caches() if settings.DEBUG: |
