Skip to content

Commit b9c3055

Browse files
committed
Throw nav2_core exceptions
Signed-off-by: redvinaa <[email protected]>
1 parent 1bdbddd commit b9c3055

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

nav2_mppi_controller/src/path_handler.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -191,11 +191,11 @@ geometry_msgs::msg::PoseStamped PathHandler::getTransformedGoal()
191191
auto goal = global_plan_.poses.back();
192192
goal.header.stamp = global_plan_.header.stamp;
193193
if (goal.header.frame_id.empty()) {
194-
throw std::runtime_error("Goal pose has an empty frame_id");
194+
throw nav2_core::ControllerTFError("Goal pose has an empty frame_id");
195195
}
196196
geometry_msgs::msg::PoseStamped transformed_goal;
197197
if (!transformPose(costmap_->getGlobalFrameID(), goal, transformed_goal)) {
198-
throw std::runtime_error("Unable to transform goal pose into costmap frame");
198+
throw nav2_core::ControllerTFError("Unable to transform goal pose into costmap frame");
199199
}
200200
return transformed_goal;
201201
}

0 commit comments

Comments
 (0)