diff --git a/drum/links/models.py b/drum/links/models.py index 589d4dd..5107cdc 100644 --- a/drum/links/models.py +++ b/drum/links/models.py @@ -15,7 +15,7 @@ from django.core.urlresolvers import reverse from django.db import models from django.db.models import Q -from django.db.models.signals import post_save, post_delete +from django.db.models.signals import post_save, pre_delete from django.dispatch import receiver from django.utils.encoding import python_2_unicode_compatible @@ -76,7 +76,7 @@ def __str__(self): @receiver(post_save, sender=Rating) -@receiver(post_delete, sender=Rating) +@receiver(pre_delete, sender=Rating) def karma(sender, **kwargs): """ Each time a rating is saved, check its value and modify the