Removed "\" from secret key generation, to avoid accidental escapes in key. Based on patch by user cam.turn in Issue 337.

This commit is contained in:
Griatch 2012-12-12 02:27:50 +01:00
parent 9d79299d16
commit 2d206c5e68

View file

@ -32,7 +32,7 @@ if not os.path.exists('settings.py'):
# make random secret_key.
import random, string
secret_key = list((string.letters + string.digits + string.punctuation).replace("'",'"'))
secret_key = list((string.letters + string.digits + string.punctuation).replace("\\","").replace("'",'"'))
random.shuffle(secret_key)
secret_key = "".join(secret_key[:40])