fix: format param force to string

This commit is contained in:
Vick Scarlet
2026-03-30 17:49:37 +08:00
parent 59a10587a7
commit f12a147093
3 changed files with 586 additions and 462 deletions
+1 -1
View File
@@ -246,7 +246,7 @@ class Life {
}
format(discription) {
return discription.replaceAll(/\{\s*[0-9a-zA-Z_-]+\s*?\}/g, (match) => this.#format(match));
return `${discription}`.replaceAll(/\{\s*[0-9a-zA-Z_-]+\s*?\}/g, (match) => this.#format(match));
}
#format(key) {