Skip to content

Commit 1ed9733

Browse files
core: services: ardupilot_manager: Fix response model when no board is selected
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
1 parent f3f6681 commit 1ed9733

File tree

1 file changed

+3
-1
lines changed
  • core/services/ardupilot_manager/api/v1/routers

1 file changed

+3
-1
lines changed

core/services/ardupilot_manager/api/v1/routers/index.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,9 @@ async def install_firmware_from_file(
168168
await autopilot.start_ardupilot()
169169

170170

171-
@index_router_v1.get("/board", response_model=FlightController, summary="Check what is the current running board.")
171+
@index_router_v1.get(
172+
"/board", response_model=Optional[FlightController], summary="Check what is the current running board."
173+
)
172174
def get_board() -> Any:
173175
return autopilot.current_board
174176

0 commit comments

Comments
 (0)