simple_offboard: error on lack of mavros/state

This commit is contained in:
Oleg Kalachev
2017-12-28 03:53:17 +03:00
parent e6e5e1a299
commit daddb30698

View File

@@ -307,7 +307,7 @@ handle_lock = Lock()
def handle(req):
global current_pub, current_msg, current_req
if not state.connected:
if not state or not state.connected:
return {'message': 'No connection to the FCU'}
if isinstance(req, srv.NavigateRequest) and req.speed <= 0: