Skip to content

FATAL ERROR: v8::ToLocalChecked Empty MaybeLocal. #15

@m-s-sh

Description

@m-s-sh

Hi,
in case FrameBuffer::FrameBuffer fails (I go that myself, but saw it also here) it will never show the right error message, because will be shadowed by

FATAL ERROR: v8::ToLocalChecked Empty MaybeLocal.

Reason for it is code in

Local<Object> FrameBuffer::NewInstance(Local<Value> arg, Local<Value> arg2)

you are using

.ToLocalChecked();

and it will fail in case object is null.
I think it needs to be replaced by the following

.FromMaybe(v8::Local<v8::Object>())

I can do the change if you also agree.

By the way throwing execution in constructor is not so good idea.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions