Skip to content

Commit e85eb03

Browse files
Apply suggestions from code review
style: update from review Co-authored-by: Davide Faconti <davide.faconti@gmail.com>
1 parent 421e5c0 commit e85eb03

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

behaviortree_ros2/include/behaviortree_ros2/bt_topic_sub_node.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ class RosTopicSubNode : public BT::ConditionNode
7676
rclcpp::CallbackGroup::SharedPtr callback_group;
7777
rclcpp::executors::SingleThreadedExecutor callback_group_executor;
7878
boost::signals2::signal<void (const std::shared_ptr<TopicT>)> broadcaster;
79-
std::shared_ptr<TopicT> last_msg = nullptr;
79+
std::shared_ptr<TopicT> last_msg;
8080

8181

8282
};
@@ -319,7 +319,7 @@ template<class T> inline
319319
auto status = CheckStatus (onTick(last_msg_));
320320
if (clearProcessedMessage())
321321
{
322-
last_msg_ = nullptr;
322+
last_msg_.reset();
323323
}
324324
return status;
325325
}

0 commit comments

Comments
 (0)