Skip to content

Commit

Permalink
refactor: check if dnd item exists before accessing data
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisvxd committed Dec 27, 2024
1 parent d247449 commit 4eb39ff
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ export const findDeepestCandidate = (
filteredCandidates.reverse();

const zone = getZoneId(filteredCandidates[0]);
const area = filteredCandidates[0].data.areaId || null;
const area = filteredCandidates[0]?.data.areaId;

return { zone, area };
}
Expand Down

0 comments on commit 4eb39ff

Please sign in to comment.