summaryrefslogtreecommitdiff
path: root/script/vm/node.lua
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2022-04-22 00:47:13 +0800
committer最萌小汐 <sumneko@hotmail.com>2022-04-22 00:47:13 +0800
commit533b04430eb34dbfb2e59f6f8d88f127e69ed133 (patch)
tree8a6a653a7ef4670a6e7631a7f3c8e6764e8bafea /script/vm/node.lua
parentd16545d285de2451b3d2c0a03cc299ef18ac0ca0 (diff)
downloadlua-language-server-533b04430eb34dbfb2e59f6f8d88f127e69ed133.zip
only error in TEST
Diffstat (limited to 'script/vm/node.lua')
-rw-r--r--script/vm/node.lua6
1 files changed, 5 insertions, 1 deletions
diff --git a/script/vm/node.lua b/script/vm/node.lua
index 81d9f335..87fcc0c5 100644
--- a/script/vm/node.lua
+++ b/script/vm/node.lua
@@ -165,7 +165,11 @@ end
---@param cover? boolean
function vm.setNode(source, node, cover)
if not node then
- error('Can not set nil node')
+ if TEST then
+ error('Can not set nil node')
+ else
+ log.error('Can not set nil node')
+ end
end
if source.type == 'global' then
error('Can not set node to global')