diff --git a/stock_barcodes/wizard/stock_barcodes_read.py b/stock_barcodes/wizard/stock_barcodes_read.py index 82cd2d792ef..7058f3c3dad 100644 --- a/stock_barcodes/wizard/stock_barcodes_read.py +++ b/stock_barcodes/wizard/stock_barcodes_read.py @@ -618,7 +618,7 @@ def action_create_package(self): def action_clean_values(self): options = self.option_group_id.option_ids - options_to_clean = options.filtered("clean_after_done") + options_to_clean = options.filtered(lambda op: op.clean_after_done and op.field_name in self) for option in options_to_clean: if option.field_name == "result_package_id" and self.keep_result_package: continue