Merge remote-tracking branch 'mlh/license' into license
This commit is contained in:
commit
96d60c271a
@ -108,7 +108,6 @@ module Homebrew
|
|||||||
RUBY
|
RUBY
|
||||||
|
|
||||||
fa.audit_license
|
fa.audit_license
|
||||||
p fa.problems
|
|
||||||
expect(fa.problems.first).to match "No license specified for package."
|
expect(fa.problems.first).to match "No license specified for package."
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@ -477,8 +477,8 @@ module GitHub
|
|||||||
end
|
end
|
||||||
|
|
||||||
def get_repo_license(user, repo)
|
def get_repo_license(user, repo)
|
||||||
res = GitHub.open_api("#{GitHub::API_URL}/repos/#{user}/#{repo}/license")
|
response = GitHub.open_api("#{GitHub::API_URL}/repos/#{user}/#{repo}/license")
|
||||||
return unless res.key?("license")
|
return unless response.key?("license")
|
||||||
|
|
||||||
res["license"]["spdx_id"]
|
res["license"]["spdx_id"]
|
||||||
rescue GitHub::HTTPNotFoundError
|
rescue GitHub::HTTPNotFoundError
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user