Commits

Waldemar Kornewald committed 79f1b30

allow to enable appstats middleware

Comments (0)

Files changed (1)

 if settings.DEBUG and 'django.contrib.staticfiles' in settings.INSTALLED_APPS:
     from django.contrib.staticfiles.handlers import StaticFilesHandler
     application = StaticFilesHandler(application)
+
+if getattr(settings, 'ENABLE_APPSTATS', False):
+    from google.appengine.ext.appstats.recording import appstats_wsgi_middleware
+    application = appstats_wsgi_middleware(application)