diff options
| author | mo khan <mo.khan@gmail.com> | 2019-10-22 20:24:29 +0000 |
|---|---|---|
| committer | mo khan <mo.khan@gmail.com> | 2019-10-22 20:24:29 +0000 |
| commit | 431f07f8d11b2bc2a8fd09351a4323c9df676822 (patch) | |
| tree | 4f40b60925a4edf8eace71ae8af65bb5d67c7b6b /lib/license/management/report | |
| parent | 7f175952a5a047d785b5ea72c15a10642523c62a (diff) | |
| parent | 561556fbd1f59492cfa8fdd790f2ce39c90f3a8d (diff) | |
Merge branch 'remove-tech-debt' into 'master'v1.7.2
Remove feature flags and temporary mappings
See merge request gitlab-org/security-products/license-management!75
Diffstat (limited to 'lib/license/management/report')
| -rw-r--r-- | lib/license/management/report/v1.rb | 8 | ||||
| -rw-r--r-- | lib/license/management/report/v2.rb | 2 |
2 files changed, 2 insertions, 8 deletions
diff --git a/lib/license/management/report/v1.rb b/lib/license/management/report/v1.rb index 02fd9bd..1cc8728 100644 --- a/lib/license/management/report/v1.rb +++ b/lib/license/management/report/v1.rb @@ -14,7 +14,7 @@ module License private # when a dependency has multiple licenses, this will join the licenses into a single name - # this defect was backported from the html2json version of this script. + # this defect was backported from the [html2json](https://gitlab.com/gitlab-org/security-products/license-management/blob/7f175952a5a047d785b5ea72c15a10642523c62a/html2json.js) version of this script. def license_summary dependencies .map { |dependency| join_license_names(dependency.licenses) } @@ -67,17 +67,11 @@ module License end def license_data(license) - return repository.item_for(license, spdx: false) if canonicalize? - { 'name' => license.name.split(/[\r\n]+/)[0], 'url' => license.url || '' } end - - def canonicalize? - ENV.fetch('LM_V1_CANONICALIZE', 'false') == 'true' - end end end end diff --git a/lib/license/management/report/v2.rb b/lib/license/management/report/v2.rb index 5df6af7..810d191 100644 --- a/lib/license/management/report/v2.rb +++ b/lib/license/management/report/v2.rb @@ -26,7 +26,7 @@ module License end def data_for(license) - repository.item_for(license, spdx: true) + repository.item_for(license) end def map_from(dependency) |
