Skip to content

Commit

Permalink
refactor: Reflect changes in Cluster class (mingrammer#653)
Browse files Browse the repository at this point in the history
  • Loading branch information
gabriel-tessier authored and ngruelaneo committed Nov 25, 2022
1 parent e150842 commit 09944ab
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions diagrams/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -260,11 +260,8 @@ def __exit__(self, exc_type, exc_value, traceback):
self._diagram.subgraph(self.dot)
setcluster(self._parent)

def _validate_direction(self, direction: str):
direction = direction.upper()
if direction in self.__directions:
return True
return False
def _validate_direction(self, direction: str) -> bool:
return direction.upper() in self.__directions

def node(self, nodeid: str, label: str, **attrs) -> None:
"""Create a new node in the cluster."""
Expand Down

0 comments on commit 09944ab

Please sign in to comment.