Skip to content

Commit

Permalink
fix: article with only one tag cause a fatal error
Browse files Browse the repository at this point in the history
  • Loading branch information
bennyxguo committed Aug 9, 2023
1 parent cd9bae9 commit 7478780
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/components/ArticleCard/src/HorizontalArticle.vue
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,10 @@

<ul>
<template v-if="post.tags && post.tags.length > 0">
<li v-for="index in numberOfTags" :key="post.tags[index].slug">
<li
v-for="index in numberOfTags - 1"
:key="post.tags[index].slug"
>
<em># {{ post.tags[index].name }}</em>
</li>
</template>
Expand Down

0 comments on commit 7478780

Please sign in to comment.