FIX: ConfigOptionBoolsNullable change_opt_value

Jira: STUDIO-8622
Change-Id: Ic0964a27b9f586d2a3e5360784eec7e42c4225ba
This commit is contained in:
chunmao.guo 2024-07-24 15:13:59 +08:00 committed by Lane.Wei
parent ff02a5e2ac
commit 476fe2ffd6
1 changed files with 1 additions and 1 deletions

View File

@ -108,7 +108,7 @@ void change_opt_value(DynamicPrintConfig& config, const t_config_option_key& opt
try{
if (config.def()->get(opt_key)->type == coBools && config.def()->get(opt_key)->nullable) {
auto vec_new = std::make_unique<ConfigOptionBoolsNullable>(1, boost::any_cast<unsigned char>(value) );
auto vec_new = std::make_unique<ConfigOptionBoolsNullable>(std::vector<unsigned char>{boost::any_cast<unsigned char>(value)});
config.option<ConfigOptionBoolsNullable>(opt_key)->set_at(vec_new.get(), opt_index, 0);
return;
}