Skip to content

Commit 82b73af

Browse files
committed
chore: code rabbit fixes
1 parent 1c69af8 commit 82b73af

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

apps/web/src/routes/_app/dashboard.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ const RouteComponent = () => {
5656
const recordCounter =
5757
instrumentInfo?.map((title) => {
5858
return {
59+
id: title.id,
5960
count: recordIds?.filter((val) => val === title.id).length ?? 0,
6061
instrumentTitle: title.title
6162
};
@@ -212,7 +213,7 @@ const RouteComponent = () => {
212213
</p>
213214
)}
214215
<AnimatePresence mode="popLayout">
215-
{userInfoQuery.data.map((user, i) => {
216+
{userInfoQuery.data?.map((user, i) => {
216217
return (
217218
<motion.li
218219
layout
@@ -302,7 +303,7 @@ const RouteComponent = () => {
302303
animate={{ opacity: 1, y: 0 }}
303304
exit={{ opacity: 0 }}
304305
initial={{ opacity: 0 }}
305-
key={instrument.title}
306+
key={instrument.id}
306307
transition={{ bounce: 0.2, delay: 0.15 * i, duration: 1.5, type: 'spring' }}
307308
>
308309
<div className="flex justify-between gap-4">

0 commit comments

Comments
 (0)