X-Git-Url: https://git.cworth.org/git?p=turbot;a=blobdiff_plain;f=turbot%2Finteraction.py;h=d87d27ac1a6827a9da4f6392245e96328440de6e;hp=507da76741730f2944962b10306a1de42c2696d6;hb=940e3c1f51b16916d997e84a9464fa8674244b85;hpb=375bba612d7f18369301f2e75529c07a9cc81bf8 diff --git a/turbot/interaction.py b/turbot/interaction.py index 507da76..d87d27a 100644 --- a/turbot/interaction.py +++ b/turbot/interaction.py @@ -928,13 +928,20 @@ def new_puzzle(turb, body): return bot_reply("Sorry, this channel doesn't appear to " + "be a hunt or puzzle channel") + # We used puzzle (if available) to select the initial round(s) + puzzle = puzzle_for_channel(turb, channel_id) + initial_rounds = None + if puzzle: + initial_rounds=puzzle.get("rounds", None) + round_options = hunt_rounds(turb, hunt['hunt_id']) if len(round_options): round_options_block = [ multi_select_block("Round(s)", "rounds", "Existing round(s) this puzzle belongs to", - round_options) + round_options, + initial_options=initial_rounds) ] else: round_options_block = []