diff --git a/cmd-list-keys.c b/cmd-list-keys.c index 6c0fec67..4f2c9dd3 100644 --- a/cmd-list-keys.c +++ b/cmd-list-keys.c @@ -195,10 +195,6 @@ cmd_list_keys_exec(struct cmd *self, struct cmdq_item *item) } sort_crit.reversed = args_has(args, 'r'); - prefix = cmd_list_keys_get_prefix(args); - single = args_has(args, '1'); - notes_only = args_has(args, 'N'); - if ((tablename = args_get(args, 'T')) != NULL) { table = key_bindings_get_table(tablename, 0); if (table == NULL) { @@ -207,6 +203,10 @@ cmd_list_keys_exec(struct cmd *self, struct cmdq_item *item) } } + prefix = cmd_list_keys_get_prefix(args); + single = args_has(args, '1'); + notes_only = args_has(args, 'N'); + if ((template = args_get(args, 'F')) == NULL) template = LIST_KEYS_TEMPLATE;