(self, **kwargs)
| 164 | slug_field = "purl" |
| 165 | |
| 166 | def get_context_data(self, **kwargs): |
| 167 | context = super().get_context_data(**kwargs) |
| 168 | package = self.object |
| 169 | context["package"] = package |
| 170 | context["affected_by_vulnerabilities"] = package.affected_by.order_by("vulnerability_id") |
| 171 | # Ghost package should not fix any vulnerability. |
| 172 | context["fixing_vulnerabilities"] = ( |
| 173 | None if package.is_ghost else package.fixing.order_by("vulnerability_id") |
| 174 | ) |
| 175 | context["package_search_form"] = PackageSearchForm(self.request.GET) |
| 176 | context["fixed_package_details"] = package.fixed_package_details |
| 177 | |
| 178 | context["history"] = list(package.history) |
| 179 | return context |
| 180 | |
| 181 | def get_object(self, queryset=None): |
| 182 | if queryset is None: |
nothing calls this directly
no test coverage detected