def send_delete_topic_email(email, topic): token = gen_salt(16) key = 'account:delete-topic:%s' % token redis.set(key, topic.id, ONE_DAY) url = full_url('account.delete_topic', token=token) title = 'Deteting %s' % topic.title text = '%s\n\n%s' % (title, url) run_task(send_text, email, title, text)
def create_email_signature(email, alt='signup'): # save email to redis token = gen_salt(16) key = 'account:%s:%s' % (alt, token) redis.set(key, email.lower(), ONE_DAY) return token