aboutsummaryrefslogtreecommitdiffstats
path: root/pysite/constants.py
diff options
context:
space:
mode:
authorGravatar Gareth Coles <[email protected]>2018-03-29 10:10:45 +0100
committerGravatar Gareth Coles <[email protected]>2018-03-29 10:10:45 +0100
commitbcbada49e27136725c4cde1567e95107d5fd5ff8 (patch)
tree3d02712dd35e2328260f3a9442e449ed4338274f /pysite/constants.py
parentOAuth fixes (diff)
Add PREFERRED_URL_SCHEME env var to fix `url_for()`
Diffstat (limited to 'pysite/constants.py')
-rw-r--r--pysite/constants.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/pysite/constants.py b/pysite/constants.py
index 03b660d6..3ccebf18 100644
--- a/pysite/constants.py
+++ b/pysite/constants.py
@@ -27,12 +27,14 @@ SERVER_ID = 267624335836053506
DISCORD_API_ENDPOINT = "https://discordapp.com/api"
DISCORD_OAUTH_REDIRECT = "/auth/discord"
-DISCORD_OAUTH_AUTHORIZED = environ.get("DISCORD_OAUTH_AUTHORIZED", "https://pythondiscord.com/auth/discord/authorized")
+DISCORD_OAUTH_AUTHORIZED = "/auth/discord/authorized"
DISCORD_OAUTH_ID = environ.get('DISCORD_OAUTH_ID', '')
DISCORD_OAUTH_SECRET = environ.get('DISCORD_OAUTH_SECRET', '')
DISCORD_OAUTH_SCOPE = 'identify email guilds.join'
OAUTH_DATABASE = "oauth_data"
+PREFERRED_URL_SCHEME = environ.get("PREFERRED_URL_SCHEME", "https") # Change this in testing to "http"
+
ERROR_DESCRIPTIONS = {
# 5XX
500: "The server encountered an unexpected error ._.",