@@ -457,26 +457,22 @@ def _config_callback(
457457 ):
458458 logging .error ("MQTT topics cannot be changed via MQTT" )
459459
460+
460461 if (
461462 "tripod_longitude" in config
462- or "tripod_latitude" in config
463- or "tripod_altitude" in config
463+ and "tripod_latitude" in config
464+ and "tripod_altitude" in config
464465 ):
465- if (
466- "tripod_longitude" in config
467- and "tripod_latitude" in config
468- and "tripod_altitude" in config
469- ):
470- self .camera .update_tripod_position (
471- config ["tripod_longitude" ],
472- config ["tripod_latitude" ],
473- config ["tripod_altitude" ],
474- )
475-
476- else :
477- logging .error (
478- "Tripod longitude, latitude, and altitude must be set together"
479- )
466+ self .camera .update_tripod_position (
467+ config ["tripod_longitude" ],
468+ config ["tripod_latitude" ],
469+ config ["tripod_altitude" ],
470+ )
471+
472+ else :
473+ logging .error (
474+ "Tripod longitude, latitude, and altitude must be set together"
475+ )
480476
481477 self .heartbeat_interval = config .get (
482478 "heartbeat_interval" , self .heartbeat_interval
0 commit comments