mirror of
https://github.com/marko-js/marko.git
synced 2025-12-08 19:26:05 +00:00
Marko v3: Check to avoid bad semicolon when inserting code
This commit is contained in:
parent
5ee4d8fc97
commit
fcd2cad02c
@ -364,6 +364,8 @@ class Generator {
|
||||
// Do nothing
|
||||
} else if (this._code.endsWith(';')) {
|
||||
this._code += '\n';
|
||||
} else if (this._code.endsWith('\n' + this.currentIndent)) {
|
||||
// Do nothing
|
||||
} else {
|
||||
this._code += ';\n';
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user