Skip to content

Commit

Permalink
fix(weekly): Number of stories without categories
Browse files Browse the repository at this point in the history
  • Loading branch information
bahlo committed Oct 29, 2023
1 parent 5d2c0f5 commit c4d1c8e
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/pages/weekly/index.astro
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,11 @@ const issues = (await getCollection("weekly"))
<!DOCTYPE html>
<html lang="en" class="weekly">
<head>
<BaseHead title={WEEKLY_TITLE} description={WEEKLY_DESCRIPTION} image="/weekly/og-image.png" />
<BaseHead
title={WEEKLY_TITLE}
description={WEEKLY_DESCRIPTION}
image="/weekly/og-image.png"
/>
<style>
ul {
list-style: none;
Expand Down Expand Up @@ -67,7 +71,9 @@ const issues = (await getCollection("weekly"))
{(issue.data.categories || []).reduce(
(acc, category) => acc + category.stories.length,
0
) || "?"}
) ||
(issue.data.stories ?? []).length ||
"?"}
stories
</span>
</li>
Expand Down

0 comments on commit c4d1c8e

Please sign in to comment.