summaryrefslogtreecommitdiff
path: root/server/src
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2019-01-30 16:10:05 +0800
committer最萌小汐 <sumneko@hotmail.com>2019-01-30 16:10:05 +0800
commit3181ca73444cc96d78b6f1cbc06b53fbae7b1b28 (patch)
tree79f51c1abe122312009f3dadc615392b13135663 /server/src
parent92e665a6f890dec8bb8f04b410e3695415d04628 (diff)
downloadlua-language-server-3181ca73444cc96d78b6f1cbc06b53fbae7b1b28.zip
修正一个泄漏
Diffstat (limited to 'server/src')
-rw-r--r--server/src/core/value.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/server/src/core/value.lua b/server/src/core/value.lua
index 6105c97c..900d022c 100644
--- a/server/src/core/value.lua
+++ b/server/src/core/value.lua
@@ -184,7 +184,9 @@ function mt:removeUri(uri)
if self._child then
for name, field in pairs(self._child) do
field.uris[uri] = nil
- if not next(field.uris) then
+ if next(field.uris) then
+ field.value:removeUri(uri)
+ else
self._child[name] = nil
end
end