Django

Code

Changeset 3766

Show
Ignore:
Timestamp:
09/17/06 04:19:50 (2 years ago)
Author:
utrebec
Message:

[full-history]
* Fixed 'signal_name' error
# Somehow this modification got run over by trunk merge.
# I'm trying to find a better solution, but for now this will do.
# Thanks to David Cramer for error report.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/branches/full-history/django/db/models/base.py

    r3641 r3766  
    161161 
    162162    def save(self): 
    163         dispatcher.send(signal=signals.pre_save, sender=self.__class__, instance=self
     163        dispatcher.send(signal=signals.pre_save, sender=self.__class__, instance=self, signal_name="pre_save"
    164164 
    165165        non_pks = [f for f in self._meta.fields if not f.primary_key] 
  • django/branches/full-history/django/db/models/query.py

    r3641 r3766  
    922922        # Pre notify all instances to be deleted 
    923923        for pk_val, instance in seen_objs[cls]: 
    924             dispatcher.send(signal=signals.pre_delete, sender=cls, instance=instance
     924            dispatcher.send(signal=signals.pre_delete, sender=cls, instance=instance, signal_name="pre_delete"
    925925 
    926926        pk_list = [pk for pk,instance in seen_objs[cls]]