Skip to content

Commit 8e5a5eb

Browse files
authored
Fix missing “Copy” button on the Windows download page (#1981)
1 parent 54891fb commit 8e5a5eb

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

include/download-instructions/windows-downloads.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,9 @@ function ws_has_sbom(string $version, string $fullVersion): bool {
125125
if (!empty($entry[$type]['path'])) {
126126
$p = $entry[$type]['path'];
127127
echo "\t", '<p><strong><a href="' . $baseDownloads . $p . '">' . $package_names[$type] . '</a></strong> <span class="size">' . $entry[$type]['size'] . '</span><br>', PHP_EOL;
128-
echo "\t", '<span class="sha256">' . ($entry[$type]['sha256'] ?? '') . '</span>', PHP_EOL;
128+
if (!empty($entry[$type]['sha256'])) {
129+
echo "\t", sha256_html($entry[$type]['sha256']), PHP_EOL;
130+
}
129131
if ($type === 'zip' && $hasSbom) {
130132
echo "\t", '<span class="sbom"><a href="' . $baseDownloads . $p . '.spdx.json">SPDX</a>|<a href="' . $baseDownloads . $p . '.cdx.json">CDX</a></span>', PHP_EOL;
131133
}

0 commit comments

Comments
 (0)