Skip to content

Commit

Permalink
fix: duplicate key error
Browse files Browse the repository at this point in the history
  • Loading branch information
ArtemSBulgakov committed Dec 19, 2024
1 parent 1a66184 commit 64414dd
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions src/components/calendar/CalendarEventPopover.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -118,9 +118,11 @@ export default function CalendarEventPopover({
{locations.map((location: string, index: number) =>
location.toUpperCase() !== "ONLINE" &&
location.toUpperCase() !== "ОНЛАЙН" ? (
<div className="flex flex-row items-center gap-1">
<div
key={index}
className="flex flex-row items-center gap-1"
>
<Link
key={index}
to="/maps"
search={{
q: location,
Expand All @@ -135,7 +137,10 @@ export default function CalendarEventPopover({
)}
</div>
) : (
<p className="flex w-full whitespace-pre-wrap py-1">
<p
key={index}
className="flex w-full whitespace-pre-wrap py-1"
>
{location.concat(
index !== locations.length - 1 ? " / " : "",
)}
Expand Down

0 comments on commit 64414dd

Please sign in to comment.