This repository has been archived on 2026-10-23. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
tekstmelding/utils.py
T
2015-01-14 20:27:21 +01:00

10 lines
271 B
Python

import string
import random
def generate_activation_code(length=5):
chars = string.ascii_lowercase + string.digits
# remove easily misinterpreted chars
chars = chars.translate(None, '0oil1wv')
return ''.join(random.choice(chars) for _ in range(length))