diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 8239e7d60..b74997a4b 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -3,7 +3,7 @@ # These pre-commit hooks mirror the Github CI, so running them locally will catch errors earlier. repos: - repo: https://github.com/rubocop/rubocop - rev: v1.76.0 + rev: v1.77.0 hooks: - id: rubocop - repo: https://github.com/syntaqx/git-hooks diff --git a/lib/gem_compact_index_client.rb b/lib/gem_compact_index_client.rb index 16836907c..b68ec4946 100644 --- a/lib/gem_compact_index_client.rb +++ b/lib/gem_compact_index_client.rb @@ -31,6 +31,6 @@ class BasicCompactIndexClient return [] if data.nil? || data.empty? lines = data.split("\n") header = lines.index('---') - header ? lines[header + 1..] : lines + header ? lines[(header + 1)..] : lines end end