Skip to content

Commit

Permalink
Use max() built-in function instead of an if block
Browse files Browse the repository at this point in the history
  • Loading branch information
atodorov committed Feb 26, 2024
1 parent 91f9af3 commit 60b0504
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions tcms/testplans/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -192,8 +192,7 @@ def tree_view_html(self):
</div> <!-- end-node -->"""

# indent
if test_plan.tree_depth > previous_depth:
previous_depth = test_plan.tree_depth
previous_depth = max(test_plan.tree_depth, previous_depth)

# outdent
did_outdent = False
Expand Down

0 comments on commit 60b0504

Please sign in to comment.