Skip to content

Commit cb2e1d4

Browse files
committed
chore: wip
1 parent 4714cca commit cb2e1d4

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/extract.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,7 @@ function cleanOutput(output: string): string {
265265
.replace(/\n+/g, '\n')
266266
.replace(/;\n\}/g, ';\n}')
267267
.replace(/\{;/g, '{')
268-
.replace(/\};\n/g, '}\n\n')
268+
.replace(/\};\n/g, '};\n\n')
269269
.replace(/\}\n(?!$)/g, '}\n\n')
270270
.replace(/\n{3,}/g, '\n\n')
271271
.replace(/;\n(\s*)\}/g, ';\n$1\n$1}')
@@ -282,6 +282,7 @@ function cleanOutput(output: string): string {
282282
.replace(/declare function ([^(]+)\(([^)]+)\): ([^;]+)\);/g, 'declare function $1($2): $3;')
283283
.replace(/declare declare/g, 'declare')
284284
.replace(/\):;/g, ');') // Fix invalid ending
285+
.replace(/;\n/g, ';\n') // Ensure semicolons are preserved
285286
.trim()
286287

287288
logDebug('Cleaned output:', result)

0 commit comments

Comments
 (0)