From ef21950599c85d85338a61d2c0758f499c87b861 Mon Sep 17 00:00:00 2001 From: Jelle De Loecker Date: Sun, 5 May 2024 11:03:54 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Fix=20element=20function=20body?= =?UTF-8?q?=20source=20code=20not=20being=20closed=20properly?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/parser/function_body.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lib/parser/function_body.js b/lib/parser/function_body.js index 0f984a5..0e79639 100644 --- a/lib/parser/function_body.js +++ b/lib/parser/function_body.js @@ -102,7 +102,7 @@ FunctionBody.setMethod(function getSourceCode() { let result = '', entry; - + for (entry of this.content) { if (entry.source) { @@ -115,6 +115,11 @@ FunctionBody.setMethod(function getSourceCode() { if (entry.function_body) { result += entry.function_body.getSourceCode(); + + if (entry.function_body.type == 'element') { + result += ''; + } + continue; }