From 50390c082ee794188e367077725a9bbb98a21cb5 Mon Sep 17 00:00:00 2001 From: Matt Seddon Date: Tue, 23 Nov 2021 13:14:18 +1100 Subject: [PATCH] remove destructor unref as per https://github.com/nodejs/node-addon-api/issues/998 --- src/core/reference.cc | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/core/reference.cc b/src/core/reference.cc index a84eb5c..0eb2e5d 100644 --- a/src/core/reference.cc +++ b/src/core/reference.cc @@ -7,9 +7,7 @@ PythonReference::PythonReference(PythonObject *scope) : mScope(scope) { } PythonReference::~PythonReference() { - if (isRef) { - mScope->Unref(); - } + } template T *PythonReference::Unwrap(PyObject *wrapped) {