fixup! Fix stomping of last_option_requires_param

Fix accidental misuse of maybe_t boolean operator instead of maybe_t payload.
This commit is contained in:
Mahmoud Al-Qudsi 2022-09-25 13:33:30 -05:00
parent 3ebfba7f5b
commit ff00d3ca08

View file

@ -879,7 +879,7 @@ bool completer_t::complete_param_for_command(const wcstring &cmd_orig, const wcs
// Only override a true last_option_requires_param value with a false one
if (last_option_requires_param.has_value()) {
last_option_requires_param =
last_option_requires_param && o.result_mode.requires_param;
*last_option_requires_param && o.result_mode.requires_param;
} else {
last_option_requires_param = o.result_mode.requires_param;
}