Skip to content

Commit da6af65

Browse files
committed
minor fix to keep newer mypy happy
1 parent bcfd0d2 commit da6af65

File tree

1 file changed

+2
-1
lines changed
  • openapi_python_client/parser/properties

1 file changed

+2
-1
lines changed

openapi_python_client/parser/properties/union.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -152,9 +152,10 @@ def process_items(
152152
not isinstance(sub_properties, PropertyError)
153153
and len([p for p in sub_properties if isinstance(p, HasNamedClass)]) == 1
154154
):
155+
already_processed_props = sub_properties
155156

156157
def _use_same_name_as_parent_for_that_one_variant(index: int) -> str:
157-
for i, p in enumerate(sub_properties):
158+
for i, p in enumerate(already_processed_props):
158159
if i == index and isinstance(p, HasNamedClass):
159160
return name
160161
return _add_index_suffix_to_variant_names(index)

0 commit comments

Comments
 (0)