hotdoc: move None check to caller of set_arg_value

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
Paolo Bonzini authored and Paolo Bonzini committed 2026-09-10 08:32:38 +02:00
1 parent 11b0e79dca
commit 81c998f7d7
1 file changed
+3 -5
+3 -5
View File
@@ -99,15 +99,13 @@ class HotdocTargetBuilder:
argname = option.strip("-").replace("-", "_")
value = self.kwargs.pop(argname) # type: ignore[misc]
if value is not None and value_processor:
if value is None:
return
if value_processor:
value = value_processor(value)
self.set_arg_value(option, value)
def set_arg_value(self, option: str, value: TYPE_var) -> None:
if value is None:
return
if isinstance(value, bool):
if value:
self.cmd.append(option)