Fixes #3405: no annotations in pictures.
[wolnelektury.git] / apps / stats / utils.py
index 543f863..474d1b5 100644 (file)
@@ -47,7 +47,8 @@ def piwik_track(klass_or_method):
         call_func = klass_or_method
 
     def wrap(self, request, *args, **kw):
-        track_request.delay(piwik_url(request))
+        if getattr(request, 'piwik_track', True):
+            track_request.delay(piwik_url(request))
         return call_func(self, request, *args, **kw)
 
     # and wrap it