diff --git a/src/connection.cc b/src/connection.cc index 35eadde..5021e73 100644 --- a/src/connection.cc +++ b/src/connection.cc @@ -238,7 +238,7 @@ NAN_METHOD(Connection::Ftable) { PGresult* res = self->lastResult; - int table = PQftable(res, info[0]->Int32Value()); + int table = PQftable(res, Nan::To(info[0]).FromJust()); info.GetReturnValue().Set(table); } @@ -249,7 +249,7 @@ NAN_METHOD(Connection::Ftablecol) { PGresult* res = self->lastResult; - int tablecol = PQftablecol(res, info[0]->Int32Value()); + int tablecol = PQftablecol(res, Nan::To(info[0]).FromJust()); info.GetReturnValue().Set(tablecol); }