JS dom event binding: Squash leak of string.

This commit is contained in:
Michael Drake 2020-05-24 16:25:30 +01:00
parent 74b8767ee2
commit 3bf39f7f2c

View File

@ -182,8 +182,8 @@ method Event::initEvent ()
cancellable = duk_get_boolean(ctx, 2);
exc = dom_event_init(priv->evt, text_str, bubbles, cancellable);
dom_string_unref(text_str);
if (exc != DOM_NO_ERR) {
dom_string_unref(text_str);
return 0;
}