diff options
author | 2018-02-15 14:31:13 +0000 | |
---|---|---|
committer | 2018-02-15 14:31:13 +0000 | |
commit | c09a23ef289cb1de7129c555f7fd1c4e2839bc84 (patch) | |
tree | 009d6c3995e12855b78daa0d83d9402c1a159206 /pysite/route_manager.py | |
parent | Move API validation decorator to its own file #yxdk (diff) |
Fix up API key validation and database api location
Diffstat (limited to 'pysite/route_manager.py')
-rw-r--r-- | pysite/route_manager.py | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/pysite/route_manager.py b/pysite/route_manager.py index ddd969d7..aeaec7c9 100644 --- a/pysite/route_manager.py +++ b/pysite/route_manager.py @@ -21,14 +21,10 @@ class RouteManager: ) self.db = RethinkDB() self.app.secret_key = os.environ.get("WEBPAGE_SECRET_KEY", "super_secret") - self.app.config["SERVER_NAME"] = os.environ.get("SERVER_NAME", "pythondiscord.com:8080") + self.app.config["SERVER_NAME"] = os.environ.get("", "pythondiscord.com:8080") self.app.before_request(self.db.before_request) self.app.teardown_request(self.db.teardown_request) - # Store the database in the Flask global context - with self.app.app_context(): - g.db = self.db # type: RethinkDB - # Load the main blueprint self.main_blueprint = Blueprint("main", __name__) print(f"Loading Blueprint: {self.main_blueprint.name}") |