diff --git a/frontend/src/components/Contexts/RobotContext.tsx b/frontend/src/components/Contexts/RobotContext.tsx index 8cc14c35..51f4afb8 100644 --- a/frontend/src/components/Contexts/RobotContext.tsx +++ b/frontend/src/components/Contexts/RobotContext.tsx @@ -41,6 +41,7 @@ export const RobotProvider: FC = ({ children }) => { }) registerEvent(SignalREventLabels.robotUpdated, (username: string, message: string) => { let updatedRobot: Robot = JSON.parse(message) + // The check below makes it so that it is not treated as null in the code. if (updatedRobot.model.type == null) { console.warn('Received robot update with model type null') return