]> git.openstreetmap.org Git - osqa.git/blobdiff - urls.py
Fix error when unconfirmed users ask questions
[osqa.git] / urls.py
diff --git a/urls.py b/urls.py
index 3ebc19e8073bbb10d384d52935213d96de9082f0..e56bc01331e7ad3e6e8e5e252c73a94df0df2411 100644 (file)
--- a/urls.py
+++ b/urls.py
@@ -1,11 +1,15 @@
-from django.conf.urls.defaults import *
+from django.conf.urls import patterns, url, include
 from django.utils.translation import ugettext as _
 from django.conf import settings
 
 from django.utils.translation import ugettext as _
 from django.conf import settings
 
-from django.contrib import admin
-admin.autodiscover()
-
 urlpatterns = patterns('',
 urlpatterns = patterns('',
-    (r'^%s' % settings.FORUM_SCRIPT_ALIAS, include('forum.urls')),
-    (r'^admin/', include(admin.site.urls)),
+    (r'', include('forum.urls')),
 )
 )
+
+if 'rosetta' in settings.INSTALLED_APPS:
+    urlpatterns = patterns('',
+        url(r'^rosetta/', include('rosetta.urls')),
+    ) + urlpatterns
+
+handler404 = 'forum.views.meta.page'
+handler500 = 'forum.views.meta.error_handler'