Skip to content

Commit 0ff060d

Browse files
committed
Post points is vote total
1 parent d173d51 commit 0ff060d

1 file changed

Lines changed: 3 additions & 5 deletions

File tree

app/lib/feed-item.tsx

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ const FeedItem_PostFragment = gql(/* GraphQL */ `
129129
id
130130
title
131131
url
132-
score
132+
voteTotal
133133
createdAt
134134
commentCollection {
135135
totalCount
@@ -166,10 +166,8 @@ export function FeedItem(props: {
166166
<div className="flex items-center flex-wrap pb-4 border-gray-100 mt-auto w-full">
167167
<span className="text-gray-400 mr-3 inline-flex items-center text-sm pr-3 py-1 border-r-2 border-gray-200">
168168
<PointIcon className="w-4 h-4 mr-1" />
169-
{props.post.score}{" "}
170-
{props.post.commentCollection?.totalCount === 1
171-
? "point"
172-
: "points"}
169+
{props.post.voteTotal}{" "}
170+
{props.post.voteTotal === 1 ? "point" : "points"}
173171
</span>
174172
<Link href={`/item/${props.post.id}`}>
175173
<a className="text-gray-400 mr-3 inline-flex items-center text-sm pr-3 py-1 border-r-2 border-gray-200">

0 commit comments

Comments
 (0)