Skip to content

Commit

Permalink
fix label formatting in appview-v1
Browse files Browse the repository at this point in the history
  • Loading branch information
dholms committed Mar 12, 2024
1 parent d643b5b commit 06bf4b4
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions packages/bsky/src/services/label/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -201,11 +201,15 @@ const fetchLabelsForSubjects = async (
.selectAll()
.execute()
const labelMap = res.reduce((acc, cur) => {
const { src, uri, cid, val, neg, cts } = cur
acc[cur.uri] ??= []
acc[cur.uri].push({
...cur,
cid: cur.cid === '' ? undefined : cur.cid,
neg: cur.neg,
src,
uri,
cid: cid === '' ? undefined : cid,
val,
neg: neg,
cts,
})
return acc
}, {} as Record<string, Label[]>)
Expand Down

0 comments on commit 06bf4b4

Please sign in to comment.