Skip to content

Commit 158aad0

Browse files
author
Minggang Wang
committed
Fix compiling error when using Node.js v10.12.0
This patch changes to use Nan methods instead of calling v8 object directly, which cause imcompatibility between different Node.js versions. Fix #677
1 parent 0c17b64 commit 158aad0

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/rcl_bindings.cpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1219,8 +1219,7 @@ std::unique_ptr<rmw_qos_profile_t> GetQosProfileFromObject(
12191219
qos_profile->durability = static_cast<rmw_qos_durability_policy_t>(
12201220
Nan::To<uint32_t>(durability).FromJust());
12211221
qos_profile->avoid_ros_namespace_conventions =
1222-
avoid_ros_namespace_conventions->BooleanValue(
1223-
currentContent->GetIsolate());
1222+
Nan::To<bool>(avoid_ros_namespace_conventions).FromJust();
12241223

12251224
return qos_profile;
12261225
}

0 commit comments

Comments
 (0)