Fix bugs
This commit is contained in:
parent
e4467aca08
commit
cc5ceca5bc
1 changed files with 2 additions and 5 deletions
|
|
@ -38,9 +38,6 @@ if __name__ == "__main__":
|
|||
conf_path = os.getenv("CONFIG_PATH", "./config.json")
|
||||
output_path = os.getenv("OUTPUT_PATH", "/tmp/secret-santa-result.json")
|
||||
|
||||
try:
|
||||
players = json.loads(open(output_path).read())
|
||||
except FileNotFoundError:
|
||||
players = init(conf_path, output_path)
|
||||
|
||||
@app.route("/")
|
||||
|
|
@ -50,7 +47,7 @@ if __name__ == "__main__":
|
|||
if app_token != "" and token != app_token:
|
||||
return "<p>Error: Invalid token</p>"
|
||||
|
||||
if name == "raphael":
|
||||
if name == "raphou":
|
||||
return f"<p>Hello {name}!<br/>Your secret santa target is {players[name]}<br/>Eva's secret santa target is {players['eva']}</p>"
|
||||
if name in players:
|
||||
return (
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue