Skip to content

Commit

Permalink
Merge pull request #27 from kapilPython/prpth-fix-branch
Browse files Browse the repository at this point in the history
mqtt subscribing to private path had a small bug
  • Loading branch information
yuma-m committed Jun 21, 2020
2 parents 93c48bb + 36a5bad commit 1de29e5
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/mqtt_bridge/bridge.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,9 +95,9 @@ def __init__(self, topic_from, topic_to, msg_type, frequency=None,
self._queue_size = queue_size
self._last_published = rospy.get_time()
self._interval = None if frequency is None else 1.0 / frequency

self._mqtt_client.subscribe(topic_from)
self._mqtt_client.message_callback_add(topic_from, self._callback_mqtt)
# Adding the correct topic to subscribe to
self._mqtt_client.subscribe(self._topic_from)
self._mqtt_client.message_callback_add(self._topic_from, self._callback_mqtt)
self._publisher = rospy.Publisher(
self._topic_to, self._msg_type, queue_size=self._queue_size)

Expand Down

0 comments on commit 1de29e5

Please sign in to comment.