Fix bad logic

This commit is contained in:
Luke Murphy 2020-04-11 23:07:09 +02:00
parent 324d58690d
commit 9c692f2335
No known key found for this signature in database
GPG Key ID: 5E2EF5A63E3718CC

View File

@ -20,7 +20,7 @@ def actions(ctx):
question = qlist("action", "Which Ansible action?", choices,) question = qlist("action", "Which Ansible action?", choices,)
action = prompt(question)["action"] action = prompt(question)["action"]
if action in any(("newhetzner", "rmhetzner")): if any(action in choice for choice in ["newhetzner", "rmhetzner"]):
choices = ["prod", "test", "cicd"] choices = ["prod", "test", "cicd"]
question = qlist("key", "Which Hetzner API key?", choices) question = qlist("key", "Which Hetzner API key?", choices)
key = prompt(question)["key"] key = prompt(question)["key"]