Skip to content
This repository was archived by the owner on Jan 21, 2023. It is now read-only.

Commit c86c2e8

Browse files
yt-msMidnighter
authored andcommitted
refactor: PR feedback
1 parent c387a52 commit c86c2e8

File tree

1 file changed

+9
-8
lines changed

1 file changed

+9
-8
lines changed

src/structurizr/view/view_set.py

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
"""Provide a set of views onto a software architecture model."""
1717

1818

19+
from itertools import chain
1920
from typing import TYPE_CHECKING, Iterable, List, Optional, Set
2021

2122
from pydantic import Field
@@ -311,14 +312,14 @@ def create_filtered_view(self, **kwargs) -> FilteredView:
311312

312313
def get_view(self, key: str) -> Optional[AbstractView]:
313314
"""Return the view with the given key, or None."""
314-
all_views = (
315-
self.system_landscape_views
316-
| self.system_context_views
317-
| self.container_views
318-
| self.component_views
319-
| self.deployment_views
320-
| self.dynamic_views
321-
| self.filtered_views
315+
all_views = chain(
316+
self.system_landscape_views,
317+
self.system_context_views,
318+
self.container_views,
319+
self.component_views,
320+
self.deployment_views,
321+
self.dynamic_views,
322+
self.filtered_views,
322323
)
323324
return next((view for view in all_views if view.key == key), None)
324325

0 commit comments

Comments
 (0)