Skip to content

Commit 9c818cf

Browse files
Gabriel SchulhofMylesBorins
Gabriel Schulhof
authored andcommitted
n-api: remove extra reference from test
PR-URL: #18542 Reviewed-By: Michael Dawson <[email protected]> Reviewed-By: Tiancheng "Timothy" Gu <[email protected]> Reviewed-By: Colin Ihrig <[email protected]>
1 parent 4bf8b6a commit 9c818cf

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

test/addons-napi/test_constructor/test_constructor.c

-3
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33

44
static double value_ = 1;
55
static double static_value_ = 10;
6-
napi_ref constructor_;
76

87
napi_value GetValue(napi_env env, napi_callback_info info) {
98
size_t argc = 0;
@@ -80,8 +79,6 @@ napi_value Init(napi_env env, napi_value exports) {
8079
NAPI_CALL(env, napi_define_class(env, "MyObject", NAPI_AUTO_LENGTH, New,
8180
NULL, sizeof(properties)/sizeof(*properties), properties, &cons));
8281

83-
NAPI_CALL(env, napi_create_reference(env, cons, 1, &constructor_));
84-
8582
return cons;
8683
}
8784

0 commit comments

Comments
 (0)