summaryrefslogtreecommitdiff
path: root/script/vm/value.lua
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2022-07-07 15:10:19 +0800
committer最萌小汐 <sumneko@hotmail.com>2022-07-07 15:10:19 +0800
commit0b87804cba3f24318362993ca2e32e0f95ce990d (patch)
tree18eb9d21b8b824255a18fedbbf9a6bcd9452c78f /script/vm/value.lua
parentca299b0289c0f79972d83c44baa29cde20ce31f4 (diff)
downloadlua-language-server-0b87804cba3f24318362993ca2e32e0f95ce990d.zip
#1294 fix operator `and`/`or` for boolean
Diffstat (limited to 'script/vm/value.lua')
-rw-r--r--script/vm/value.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/script/vm/value.lua b/script/vm/value.lua
index c4f8e96d..23a9f2c9 100644
--- a/script/vm/value.lua
+++ b/script/vm/value.lua
@@ -26,7 +26,7 @@ function vm.testCondition(source)
if n.name == 'false'
or n.name == 'nil' then
hasFalse = true
- else
+ elseif n.name ~= 'boolean' then
hasTrue = true
end
elseif n.type == 'nil' then