Skip to content

Commit

Permalink
fix: inspector showing NaN audio interval
Browse files Browse the repository at this point in the history
When a screen normally capable of periodic audio readouts (Bus Shelter)
had them disabled, this was incorrectly loaded as an interval of `NaN`
seconds, rather than no interval at all. This basically worked anyway
on the screens themselves, but showed up oddly in the Inspector.
  • Loading branch information
digitalcora committed Jan 27, 2025
1 parent 61ac725 commit 93f14f3
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions assets/src/apps/v2/bus_shelter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -106,12 +106,8 @@ const getAudioConfig = (): AudioConfig | null => {
);
const audioReadoutInterval = getDatasetValue("audioReadoutInterval");

if (
audioIntervalOffsetSeconds === undefined ||
audioReadoutInterval === undefined
) {
if (!audioReadoutInterval || audioIntervalOffsetSeconds === undefined)
return null;
}

return {
intervalOffsetSeconds: parseInt(audioIntervalOffsetSeconds),
Expand Down

0 comments on commit 93f14f3

Please sign in to comment.