Skip to content

Commit

Permalink
remove unnecessary list comprehension to fix CI
Browse files Browse the repository at this point in the history
  • Loading branch information
Byron committed Sep 22, 2023
1 parent e98f57b commit 832b6ee
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion git/refs/symbolic.py
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ def _check_ref_name_valid(ref_path: PathLike) -> None:
raise ValueError(f"Invalid reference '{ref_path}': references cannot end with a forward slash (/)")
elif previous == "@" and one_before_previous is None:
raise ValueError(f"Invalid reference '{ref_path}': references cannot be '@'")
elif any([component.endswith(".lock") for component in str(ref_path).split("/")]):
elif any(component.endswith(".lock") for component in str(ref_path).split("/")):
raise ValueError(
f"Invalid reference '{ref_path}': references cannot have slash-separated components that end with"
f" '.lock'"
Expand Down

0 comments on commit 832b6ee

Please # to comment.