diff --git a/pcbnew/api/api_handler_pcb.cpp b/pcbnew/api/api_handler_pcb.cpp index d47b8b12fd..b8f5b8fd38 100644 --- a/pcbnew/api/api_handler_pcb.cpp +++ b/pcbnew/api/api_handler_pcb.cpp @@ -1263,7 +1263,7 @@ HANDLER_RESULT API_HANDLER_PCB::handleGetNetClassForNet NetClassForNetsResponse response; BOARD* board = frame()->GetBoard(); - NETINFO_LIST nets = board->GetNetInfo(); + const NETINFO_LIST& nets = board->GetNetInfo(); google::protobuf::Any any; for( const board::types::Net& net : aCtx.Request.net() )