mirror of
https://github.com/matrix-construct/construct
synced 2025-02-19 18:20:19 +01:00
ircd::js: Fix trap constructor handler (?)
This commit is contained in:
parent
3fcd3d2bb0
commit
1adc76034c
1 changed files with 1 additions and 1 deletions
|
@ -549,7 +549,7 @@ noexcept try
|
|||
auto &trap(from(that));
|
||||
trap.debug("ctor: '%s'", trap.name().c_str());
|
||||
|
||||
object ret(JS_NewObjectForConstructor(*cx, &trap.jsclass(), args));
|
||||
object ret(JS_NewObjectWithGivenProto(*cx, &trap.jsclass(), that));
|
||||
trap.on_ctor(ret, args);
|
||||
args.rval().set(ret);
|
||||
return true;
|
||||
|
|
Loading…
Add table
Reference in a new issue