@@ -276,8 +276,8 @@ class QueryWrap : public AsyncWrap {
276276 }
277277
278278 void CallOnComplete (Local<Value> answer) {
279- Context::Scope context_scope (env ()->context ());
280279 HandleScope handle_scope (env ()->isolate ());
280+ Context::Scope context_scope (env ()->context ());
281281 Local<Value> argv[] = {
282282 Integer::New (0 , env ()->isolate ()),
283283 answer
@@ -286,8 +286,8 @@ class QueryWrap : public AsyncWrap {
286286 }
287287
288288 void CallOnComplete (Local<Value> answer, Local<Value> family) {
289- Context::Scope context_scope (env ()->context ());
290289 HandleScope handle_scope (env ()->isolate ());
290+ Context::Scope context_scope (env ()->context ());
291291 Local<Value> argv[] = {
292292 Integer::New (0 , env ()->isolate ()),
293293 answer,
@@ -298,8 +298,8 @@ class QueryWrap : public AsyncWrap {
298298
299299 void ParseError (int status) {
300300 assert (status != ARES_SUCCESS);
301- Context::Scope context_scope (env ()->context ());
302301 HandleScope handle_scope (env ()->isolate ());
302+ Context::Scope context_scope (env ()->context ());
303303 Local<Value> arg;
304304 switch (status) {
305305#define V (code ) \
@@ -800,8 +800,8 @@ void AfterGetAddrInfo(uv_getaddrinfo_t* req, int status, struct addrinfo* res) {
800800 GetAddrInfoReqWrap* req_wrap = static_cast <GetAddrInfoReqWrap*>(req->data );
801801 Environment* env = req_wrap->env ();
802802
803- Context::Scope context_scope (env->context ());
804803 HandleScope handle_scope (env->isolate ());
804+ Context::Scope context_scope (env->context ());
805805
806806 Local<Value> argv[] = {
807807 Integer::New (status, node_isolate),
0 commit comments