MCPcopy Index your code
hub / github.com/aboutcode-org/vulnerablecode / normalize_list

Function normalize_list

vulnerabilities/utils.py:617–620  ·  view source on GitHub ↗

Sort a list to ensure consistent ordering.

(lst)

Source from the content-addressed store, hash-verified

615
616
617def normalize_list(lst):
618 """Sort a list to ensure consistent ordering."""
619 lst = [x for x in lst if x]
620 return sorted(lst) if lst else []
621
622
623def canonical_value(value):

Callers 6

to_advisory_dataMethod · 0.90
compute_content_idFunction · 0.85
compute_content_id_v2Function · 0.85

Calls

no outgoing calls

Tested by 1