Commits

Anonymous committed c2e3402

added user to the template context for email delivery;

Comments (0)

Files changed (1)

registration/models.py

             ``django.contrib.sites.models.RequestSite`` (if
             not). Consult the documentation for the Django sites
             framework for details regarding these objects' interfaces.
-
+         ``user``
+            The user who has just registered
         """
         ctx_dict = {'activation_key': self.activation_key,
                     'expiration_days': settings.ACCOUNT_ACTIVATION_DAYS,
-                    'site': site}
+                    'site': site,
+                    'user': self.user }
         subject = render_to_string('registration/activation_email_subject.txt',
                                     ctx_dict )
         subject = ''.join(subject.splitlines())