mirror of
https://github.com/legop3/MultiRoombaRover.git
synced 2026-09-16 09:31:20 -04:00
guh
This commit is contained in:
+2
-2
@@ -85,8 +85,8 @@ function DriverVideoPanel() {
|
||||
const info = roverId ? sources[roverId] : null;
|
||||
const frame = useTelemetryFrame(roverId);
|
||||
const batteryConfig = useMemo(() => {
|
||||
if (!roverId) return null;
|
||||
const record = session?.roster?.find((item) => item.id === roverId);
|
||||
if (!roverId || !session?.roster) return null;
|
||||
const record = session.roster.find((item) => String(item.id) === String(roverId));
|
||||
return record?.battery ?? null;
|
||||
}, [session?.roster, roverId]);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user