Skip to content
This repository was archived by the owner on Dec 8, 2022. It is now read-only.

Commit 9b93e4f

Browse files
authored
Merge pull request #176 from codewizardshq/disable-voting
fix typo
2 parents b84bd05 + 709a4f2 commit 9b93e4f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

CodeChallenge/api/vote.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616

1717
@bp.before_request
1818
def time_gate():
19-
if not core.challenge_ended() or current_app.config["VOTING_DISABLED"]:
19+
if not core.challenge_ended() or current_app.config.get("VOTING_DISABLED", False):
2020
r = jsonify(status="error",
2121
reason="voting unavailable until code challenge ends")
2222
r.status_code = 403

CodeChallenge/config.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ class ProductionConfig(DefaultConfig):
7777
MG_LIST = os.getenv("MG_LIST")
7878
ANSWER_ATTEMPT_LIMIT = "5 per 1 minutes"
7979
CODE_CHALLENGE_START = os.getenv("CODE_CHALLENGE_START")
80-
VOTING_DISALBED = True
80+
VOTING_DISABLED = True
8181

8282

8383
class DevelopmentConfig(ProductionConfig):

0 commit comments

Comments
 (0)