MCPcopy Create free account
hub / github.com/nodejs/node-addon-api / DeletePropertyWithNapiValue

Function DeletePropertyWithNapiValue

test/object/delete_property.cc:12–18  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

10}
11
12Value DeletePropertyWithNapiValue(const CallbackInfo& info) {
13 Object obj = info[0].UnsafeAs<Object>();
14 Name key = info[1].As<Name>();
15 return Boolean::New(
16 info.Env(),
17 MaybeUnwrapOr(obj.Delete(static_cast<napi_value>(key)), false));
18}
19
20Value DeletePropertyWithNapiWrapperValue(const CallbackInfo& info) {
21 Object obj = info[0].UnsafeAs<Object>();

Callers

nothing calls this directly

Calls 3

MaybeUnwrapOrFunction · 0.85
EnvMethod · 0.80
DeleteMethod · 0.80

Tested by

no test coverage detected