Skip to content

Commit 2b117d2

Browse files
committed
Address review comments
Signed-off-by: Tushar Goel <tushar.goel.dav@gmail.com>
1 parent 21a5802 commit 2b117d2

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

  • vulnerabilities/importers

vulnerabilities/importers/npm.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,9 @@ def get_affected_package(self, data, package_name):
131131
)
132132
fixed_version = None
133133

134+
# We only store single fixed versions and not a range of fixed versions
135+
# If there is a single constraint in the unaffected_version_range
136+
# having comparator as ">=" then we store that as the fixed version
134137
if unaffected_version_range and len(unaffected_version_range.constraints) == 1:
135138
constraint = unaffected_version_range.constraints[0]
136139
if constraint.comparator == ">=":

0 commit comments

Comments
 (0)