Skip to content

Commit 8bb6567

Browse files
committed
fix #709
1 parent 85f19e8 commit 8bb6567

File tree

2 files changed

+15
-5
lines changed

2 files changed

+15
-5
lines changed

changelog.md

+3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# changelog
22

3+
## 2.4.2
4+
* `FIX` [#709](https://github.com./sumneko/lua-language-server/issues/709)
5+
36
## 2.4.1
47
`2021-10-2`
58
* `FIX` broken with single file

script/provider/provider.lua

+12-5
Original file line numberDiff line numberDiff line change
@@ -867,16 +867,23 @@ do
867867
end)
868868
end
869869

870+
local function refreshStatusBar()
871+
local value = config.get 'Lua.window.statusBar'
872+
if value then
873+
proto.notify('$/status/show')
874+
else
875+
proto.notify('$/status/hide')
876+
end
877+
end
878+
870879
config.watch(function (key, value)
871880
if key == 'Lua.window.statusBar' then
872-
if value then
873-
proto.notify('$/status/show')
874-
else
875-
proto.notify('$/status/hide')
876-
end
881+
refreshStatusBar()
877882
end
878883
end)
879884

885+
proto.on('$/status/refresh', refreshStatusBar)
886+
880887
files.watch(function (ev, uri)
881888
if not workspace.isReady() then
882889
return

0 commit comments

Comments
 (0)