From 86c8d2ac043715de7d48f5bca2517c589ceceebc Mon Sep 17 00:00:00 2001 From: Marly Fleitas Date: Mon, 24 Aug 2020 20:27:19 +0200 Subject: [PATCH] doc: Added required return to example (#793) PR-URL: https://github.com/nodejs/node-addon-api/pull/793 Reviewed-By: Gabriel Schulhof Reviewed-By: Michael Dawson --- doc/function.md | 1 + 1 file changed, 1 insertion(+) diff --git a/doc/function.md b/doc/function.md index c1b0fc9..610d100 100644 --- a/doc/function.md +++ b/doc/function.md @@ -30,6 +30,7 @@ Value Fn(const CallbackInfo& info) { Object Init(Env env, Object exports) { exports.Set(String::New(env, "fn"), Function::New(env)); + return exports; } NODE_API_MODULE(NODE_GYP_MODULE_NAME, Init)