Browse Source

Don't baloon forum and thread stats

Rafał Pitoń 10 years ago
parent
commit
f01c772d72
1 changed files with 3 additions and 3 deletions
  1. 3 3
      misago/threads/posting/updatestats.py

+ 3 - 3
misago/threads/posting/updatestats.py

@@ -11,11 +11,11 @@ class UpdateStatsMiddleware(PostingMiddleware):
 
     def update_forum(self):
         if self.mode == START:
-            self.forum.threads += F('threads') + 1
+            self.forum.threads = F('threads') + 1
 
         if self.mode != EDIT:
             self.forum.set_last_thread(self.thread)
-            self.forum.posts += F('posts') + 1
+            self.forum.posts = F('posts') + 1
             self.forum.update_all = True
 
     def update_thread(self):
@@ -26,7 +26,7 @@ class UpdateStatsMiddleware(PostingMiddleware):
             self.thread.set_last_post(self.post)
 
         if self.mode == REPLY:
-            self.thread.replies += F('replies') + 1
+            self.thread.replies = F('replies') + 1
 
         self.thread.update_all = True