dependabot-common 0.105.6 → 0.105.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7ebb69bf81bb4b01f846d8a68890431b70562f800dcd413393ff90306a8e3b4c
4
- data.tar.gz: a23bd9d7b11d66d0fe9cf8d1f1839a119f034e81ce39ffd219f18f9e414fe5f2
3
+ metadata.gz: d674951b3ec75206b00e758d4d5683924172234fbf235c96010236b9fbb3a527
4
+ data.tar.gz: 886c9b43121f6555540f3bba794feccf60ecc94233fa5de9d4104cdf7a18d0a2
5
5
  SHA512:
6
- metadata.gz: 2a5b5d3133bace7c25e09fb3d8a67993fe1d3ce57e5146c35d16c20817c0d759b1a933bfe60a918607dafaf28c0933efe8948b003ea0b9654c1ef978c1b39e71
7
- data.tar.gz: 89fb60c9e062187a6a7378520974c478f619e0e7196de907617f704f15737a30fb4aab65302161669803c92a9bb384e73bce092391f547bccc8d31dde55ff0ce
6
+ metadata.gz: dbbecbf5ef5d1dc7cfaa5a715fefbcc65bfc60c5b7157f9c42cedf868d66b4c5ab85f3576ac3a77e2cb5df4c180e8fea52d508900247aed067aa1d1437f10eee
7
+ data.tar.gz: bf7ee5354451fcf8ee696133f1b362d97a95ecef4609554783a992c9f7939b6578416e0014c85391602a5effb8a97abf8fca6a68ff7b9eb769e00237797c7e62
@@ -224,23 +224,22 @@ module Dependabot
224
224
 
225
225
  def fetch_github_commits
226
226
  commits =
227
- if part_of_monorepo?
227
+ begin
228
228
  # If part of a monorepo we make two requests in order to get only
229
229
  # the commits relevant to the given path
230
- path = source.directory.gsub(%r{^[./]+}, "")
230
+ path = source.directory&.gsub(%r{^[./]+}, "")
231
231
  repo = source.repo
232
232
 
233
+ args = { sha: previous_tag, path: path }.compact
233
234
  previous_commit_shas =
234
- github_client.commits(repo, sha: previous_tag, path: path).
235
- map(&:sha)
235
+ github_client.commits(repo, **args).map(&:sha)
236
236
 
237
237
  # Note: We reverse this so it's consistent with the array we get
238
238
  # from `github_client.compare(...)`
239
+ args = { sha: new_tag, path: path }.compact
239
240
  github_client.
240
- commits(repo, sha: new_tag, path: path).
241
+ commits(repo, **args).
241
242
  reject { |c| previous_commit_shas.include?(c.sha) }.reverse
242
- else
243
- github_client.compare(source.repo, previous_tag, new_tag).commits
244
243
  end
245
244
  return [] unless commits
246
245
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Dependabot
4
- VERSION = "0.105.6"
4
+ VERSION = "0.105.7"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dependabot-common
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.105.6
4
+ version: 0.105.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dependabot