Bug 27747: (QA follow-up) Make code consistent and add explicit brackets
The while statements were including the next statement, I add brackets to make it more obvious Also the highlighting was applying to [[borrowernumber|Borrow number] I removed the break to match code above and only highlight when syntax complete and correct Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This commit is contained in:
parent
3c8be8bf7a
commit
6d9e145716
1 changed files with 11 additions and 8 deletions
|
@ -1429,18 +1429,21 @@
|
|||
var ch;
|
||||
|
||||
if (stream.match("<<")) {
|
||||
while ((ch = stream.next()) != null)
|
||||
if (ch == ">" && stream.next() == ">") {
|
||||
stream.eat(">");
|
||||
return "sqlParams";
|
||||
while ((ch = stream.next()) != null) {
|
||||
if (ch == ">" && stream.next() == ">") {
|
||||
stream.eat(">");
|
||||
return "sqlParams";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (stream.match("[[")) {
|
||||
while ((ch = stream.next()) != null)
|
||||
if (ch == "]" && stream.next() == "]") break;
|
||||
stream.eat("]");
|
||||
return "columnPlaceholder";
|
||||
while ((ch = stream.next()) != null) {
|
||||
if (ch == "]" && stream.next() == "]") {
|
||||
stream.eat("]");
|
||||
return "columnPlaceholder";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
else if (stream.next() != null) {
|
||||
|
|
Loading…
Reference in a new issue