Skip to content

Commit

Permalink
Fix coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
koxudaxi committed Aug 2, 2023
1 parent d071192 commit 2e82949
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion datamodel_code_generator/model/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,9 @@ def imports(self) -> Tuple[Import, ...]:
) and not self.data_type.use_union_operator:
imports.append((IMPORT_OPTIONAL,))
else:
if self.nullable and not self.data_type.use_union_operator:
if (
self.nullable and not self.data_type.use_union_operator
): # pragma: no cover
imports.append((IMPORT_OPTIONAL,))
if self.use_annotated:
import_annotated = (
Expand Down

0 comments on commit 2e82949

Please sign in to comment.