Fix JavaScript error on packages overview page

This commit is contained in:
Jelle van der Waa 2021-06-22 21:56:12 +02:00
parent 959e535126
commit 512f8064c1
No known key found for this signature in database
GPG key ID: C06086337C50773E

View file

@ -49,6 +49,11 @@ html_header($title, $details);
<script type="text/javascript"> <script type="text/javascript">
function collapseDependsList(list) { function collapseDependsList(list) {
list = document.getElementById(list); list = document.getElementById(list);
// Packages overview page also triggers collapseDependsList, ideally the Javascript
// is only included for the package details view.
if (!list) {
return;
}
// Hide everything past a given limit. Don't do anything if we don't have // Hide everything past a given limit. Don't do anything if we don't have
// enough items, or the link already exists. // enough items, or the link already exists.