Skip to content

Commit

Permalink
Fix compilation errors related to 0592fb0
Browse files Browse the repository at this point in the history
  • Loading branch information
kkoopa committed May 28, 2016
1 parent d19af99 commit e9191c5
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions nan_maybe_43_inl.h
Original file line number Diff line number Diff line change
Expand Up @@ -217,9 +217,9 @@ NAN_INLINE Maybe<int> GetEndColumn(v8::Local<v8::Message> msg) {
NAN_INLINE MaybeLocal<v8::Object> CloneElementAt(
v8::Local<v8::Array> array
, uint32_t index) {
#if (NODE_MODULE_VERSION >= NODE_6_0_MODULE_VERSION)
v8::EscapableHandleScope handle_scope(v8::Isolate::GetCurrent());
v8::Local<v8::Context> context = GetCurrentContext();
#if (NODE_MODULE_VERSION >= NODE_6_0_MODULE_VERSION)
v8::Local<v8::Value> elem;
if (!array->Get(context, index).ToLocal(&elem)) {
return MaybeLocal<v8::Object>();
Expand All @@ -228,9 +228,9 @@ NAN_INLINE MaybeLocal<v8::Object> CloneElementAt(
if (!elem->ToObject(context).ToLocal(&obj)) {
return MaybeLocal<v8::Object>();
}
return handle_scope.Escape(obj->Clone());
return MaybeLocal<v8::Object>(handle_scope.Escape(obj->Clone()));
#else
return handle_scope.Escape(array->CloneElementAt(context, index));
return array->CloneElementAt(GetCurrentContext(), index);
#endif
}

Expand Down

0 comments on commit e9191c5

Please sign in to comment.