Generates a link to reset password

def generate_password_link(self):
        """ Generates a link to reset password """
        self.password_link = self.generate_hash(50)
        now = datetime.datetime.utcnow()
        self.password_link_expires = now + datetime.timedelta(hours=24)