Skip to content

Commit

Permalink
fixed bug
Browse files Browse the repository at this point in the history
  • Loading branch information
GMILLA92 committed Jun 20, 2024
1 parent a5e99df commit f64bc3a
Showing 1 changed file with 10 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,13 +61,17 @@ function TableResultsIndividuals (props) {
console.log(element.id)
})

const beacon = beaconsList.find(b => (b.response?.id ?? b.id) === beaconId)
const beacon = beaconsList.find(b => (b.response?.id ?? b.id) === beaconId);

return beacon
? beacon.response
? beacon.response.name
: beacon.name
: beacon.id
if (beacon) {
if (beacon.response) {
return beacon.response.name;
} else {
return beacon.name;
}
} else {
return beaconId; // Or any other default value you prefer when no beacon is found
}
}

const [columnVisibility, setColumnVisibility] = useState({
Expand Down

0 comments on commit f64bc3a

Please sign in to comment.