<commit_before>from ovp_core.emails import BaseMail

class UserMail(BaseMail):
  """
  This class is responsible for firing emails for Users
  """
  def __init__(self, user, async_mail=None):
    super(UserMail, self).__init__(user.email, async_mail)

  def sendWelcome(self, context={}):
    """
    Sent when user registers
    """
    return self.sendEmail('welcome', 'Welcome', context)


  def sendRecoveryToken(self, context):
    """
    Sent when volunteer requests recovery token
    """
    context.update({
      'user_email': user.email
      })
    return self.sendEmail('recoveryToken', 'Password recovery', context)
<commit_msg>fix getting user email for recoveryToken<commit_after>from ovp_core.emails import BaseMail

class UserMail(BaseMail):
  """
  This class is responsible for firing emails for Users
  """
  def __init__(self, user, async_mail=None):
    super(UserMail, self).__init__(user.email, async_mail)

  def sendWelcome(self, context={}):
    """
    Sent when user registers
    """
    return self.sendEmail('welcome', 'Welcome', context)


  def sendRecoveryToken(self, context):
    """
    Sent when volunteer requests recovery token
    """
    context.update({
      'user_email': self.email_address
      })
    return self.sendEmail('recoveryToken', 'Password recovery', context)

{'fraction_non_alphanumeric': 0.1165783497350492, 'fraction_numerical': 0.0, 'mean_word_length': 3.8962962962962964, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5749566', 'n_tokens_mistral': 393, 'n_tokens_neox': 378, 'n_words': 105}