Skip to content

Commit 615c2bd

Browse files
committed
true and false are keyworks in NBTT - quote accordingly (Fixes #307)
1 parent a538dc7 commit 615c2bd

File tree

1 file changed

+1
-1
lines changed
  • src/main/kotlin/com/demonwav/mcdev/nbt/tags

1 file changed

+1
-1
lines changed

src/main/kotlin/com/demonwav/mcdev/nbt/tags/NbtTag.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ fun writeString(sb: StringBuilder, s: String): StringBuilder {
5656
return sb.append('"').append(s.replace("\n", "\\n")).append('"')
5757
}
5858

59-
if (s == "bytes" || s == "ints" || s == "longs") {
59+
if (s == "bytes" || s == "ints" || s == "longs" || s == "true" || s == "false") {
6060
// keywords must be quoted
6161
return sb.append('"').append(s).append('"')
6262
}

0 commit comments

Comments
 (0)