Comparing version 1.1.48 to 1.1.49
@@ -10,2 +10,3 @@ 'use strict'; | ||
const lines = []; | ||
let next = false; | ||
@@ -17,3 +18,10 @@ for (let i = 0; i < len; i++) { | ||
if (i % 2 === 0) { | ||
lines.push('$b.addStr("' + encodeURI(item) + '");'); | ||
const lineArr = item.split('\n'); | ||
for (const lineItem of lineArr) { | ||
if (next) { | ||
next = false; | ||
continue; | ||
} | ||
lines.push('$b.addStr("' + encodeURI(lineItem) + '");'); | ||
} | ||
continue; | ||
@@ -29,8 +37,5 @@ } | ||
case '#': | ||
lines.pop(); | ||
lines.push(item.substr(1)); | ||
// 去掉下一行的换行 | ||
const next = arr[i + 1]; | ||
if (next && next.length > 0 && next.indexOf('\n') > -1) { | ||
arr[i + 1] = next.replace('\n', ''); | ||
} | ||
next = true; | ||
break; | ||
@@ -37,0 +42,0 @@ default: |
{ | ||
"name": "koa-rtapi", | ||
"version": "1.1.48", | ||
"version": "1.1.49", | ||
"description": "koa api in rtworld company", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
504827
64
12939
9