apply strictnullchecks to src/components/views/beacon/* (#10272)

This commit is contained in:
Kerry 2023-03-02 22:58:05 +13:00 committed by GitHub
parent ffa047be68
commit de6a1a661c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
11 changed files with 48 additions and 30 deletions

View file

@ -42,7 +42,7 @@ const OwnBeaconStatus: React.FC<Props & HTMLProps<HTMLDivElement>> = ({ beacon,
stoppingInProgress,
onStopSharing,
onResetLocationPublishError,
} = useOwnLiveBeacons([beacon?.identifier]);
} = useOwnLiveBeacons(beacon?.identifier ? [beacon?.identifier] : []);
// combine display status with errors that only occur for user's own beacons
const ownDisplayStatus = hasLocationPublishError || hasStopSharingError ? BeaconDisplayStatus.Error : displayStatus;