Alert user if bad key has been entered.

parent 6f069378
......@@ -104,6 +104,10 @@ def run(config):
if key == config.key:
file.save(config.upload_file)
return redirect('/')
else:
# Bad key
template = app.open_resource('templates/badkey.html')
return template.read()
template = app.open_resource('templates/index.html')
return template.read()
......
<!doctype html>
<title>Entered key is not valid</title>
<h1>Entered key is not valid. Please go back and try again with correct secret key.</h1>
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment