Skip to content

Commit 18e94fa

Browse files
committed
fix: pour le petit gr&acon qui pleur
1 parent 20e1cfe commit 18e94fa

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

src/HL/backend.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -115,14 +115,14 @@ def _get_telemetry(self) -> Dict[str, Any]:
115115
current_speed = getattr(ard, "current_speed", 0.0) if ard else 0.0
116116

117117
# Programme qui contrôle la voiture actuellement
118-
last_ctrl = int(getattr(self.server, "last_programme_control", 0) or 0)
118+
last_ctrl = int(getattr(self.server, "last_programme_control", 0))
119119
programmes = getattr(self.server, "programme", [])
120120
prog_name = None
121121
if isinstance(programmes, list) and 0 <= last_ctrl < len(programmes):
122122
prog_name = type(programmes[last_ctrl]).__name__
123123

124-
target_speed = float(getattr(self.server, "target_speed", 0.0) or 0.0)
125-
direction = float(getattr(self.server, "direction", 0.0) or 0.0)
124+
target_speed = float(getattr(self.server, "target_speed", 0.0))
125+
direction = float(getattr(self.server, "direction", 0.0))
126126

127127
return {
128128
"battery": {

0 commit comments

Comments
 (0)