mirror of
https://github.com/hexedtech/codemp-nvim.git
synced 2024-11-24 16:34:50 +01:00
fix: collect garbage when detaching for faster dc
This commit is contained in:
parent
455ec025c1
commit
8a4e6e828a
1 changed files with 3 additions and 3 deletions
|
@ -165,11 +165,11 @@ local function detach(name)
|
|||
id_buffer_map[buffer] = nil
|
||||
buffer_id_map[name] = nil
|
||||
if not CODEMP.workspace:detach(name) then
|
||||
print(" /!\\ dangling reference, detach incomplete")
|
||||
else
|
||||
print(" -- detached from buffer " .. name)
|
||||
collectgarbage("collect") -- clear dangling references
|
||||
end
|
||||
|
||||
print(" -- detached from buffer " .. name)
|
||||
|
||||
require('codemp.window').update()
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue