Skip to content

Commit 57ff76b

Browse files
committed
Fix search sorting
Signed-off-by: Tushar Goel <tushar.goel.dav@gmail.com>
1 parent 946dce1 commit 57ff76b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎vulnerabilities/models.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3443,7 +3443,7 @@ def search(self, query: str = None):
34433443
except ValueError:
34443444
# otherwise use query as a plain string
34453445
qs = qs.filter(package_url__icontains=query)
3446-
return qs.order_by("package_url").order_by("-version_rank")
3446+
return qs.order_by("type", "namespace", "name", "-version_rank")
34473447

34483448
def with_vulnerability_counts(self):
34493449
return self.annotate(

0 commit comments

Comments
 (0)