diff options
Diffstat (limited to 'src/udp_wrap.cc')
-rw-r--r-- | src/udp_wrap.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/udp_wrap.cc b/src/udp_wrap.cc index 4c7072f2a2b..b4c859e5947 100644 --- a/src/udp_wrap.cc +++ b/src/udp_wrap.cc @@ -149,6 +149,12 @@ void UDPWrap::Initialize(Local<Object> target, target->Set(env->context(), sendWrapString, swt->GetFunction(env->context()).ToLocalChecked()).FromJust(); + + Local<Object> constants = Object::New(env->isolate()); + NODE_DEFINE_CONSTANT(constants, UV_UDP_IPV6ONLY); + target->Set(context, + env->constants_string(), + constants).FromJust(); } |