From 3bb1c5e90af77edff0772db444b82ecb4efadbed Mon Sep 17 00:00:00 2001 From: Pavel Shevaev Date: Thu, 16 Mar 2023 15:43:30 +0300 Subject: [PATCH] Fixing class instances not properly released when accessed via 'bhl_native_prefix' --- tpl/macro.twig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tpl/macro.twig b/tpl/macro.twig index b92e5fc..b9f2dbd 100644 --- a/tpl/macro.twig +++ b/tpl/macro.twig @@ -600,7 +600,7 @@ Script_{{o.name|norm_name}}.Method_{{m.name}}.ReturnValue(frm, stack {% for m in o.getfuncs %} {% if has_token(m, 'bhl_native_prefix') %} - {{ _self.reg_func_native(m, 'cl', '(('~token_or(o, 'bhl_native_class', o.name)~')stack.Pop()._obj).') }} + {{ _self.reg_func_native(m, 'cl', '(('~token_or(o, 'bhl_native_class', o.name)~')stack.PopRelease()._obj).') }} {% else %} {{ _self.method_partial(o, m, 'cl') }} {% endif %}