diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index a56498de..ddac3c05 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -22,7 +22,7 @@ repos: - id: check-docstring-first - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.7.2 + rev: v0.8.0 hooks: - id: ruff - id: ruff-format diff --git a/src/cleo/io/inputs/argv_input.py b/src/cleo/io/inputs/argv_input.py index e9a7a898..d3487562 100644 --- a/src/cleo/io/inputs/argv_input.py +++ b/src/cleo/io/inputs/argv_input.py @@ -97,7 +97,7 @@ def has_parameter_option( # For short options, test for '-o' at beginning leading = value + "=" if value.startswith("--") else value - if token == value or leading != "" and token.startswith(leading): + if token == value or (leading != "" and token.startswith(leading)): return True return False @@ -129,7 +129,7 @@ def parameter_option( # For short options, test for '-o' at beginning leading = value + "=" if value.startswith("--") else value - if token == value or leading != "" and token.startswith(leading): + if token == value or (leading != "" and token.startswith(leading)): return token[len(leading)] return False