ensure that the setup step doesn't get run multiple times when opening...
the ui
This commit is contained in:
@ -108,9 +108,14 @@ function ui.set_page(p)
|
||||
})
|
||||
end
|
||||
|
||||
local setup
|
||||
--- setup all the pages
|
||||
---@param packager package the packager
|
||||
local function setup_pages(packager)
|
||||
if setup then
|
||||
return
|
||||
end
|
||||
|
||||
local header_text = ""
|
||||
|
||||
table.insert(pages, page_packages(packager))
|
||||
@ -132,6 +137,8 @@ local function setup_pages(packager)
|
||||
vim.api.nvim_win_close(ui.winnr, false)
|
||||
ui.winnr = nil
|
||||
end, { buffer = ui.bufnr })
|
||||
|
||||
setup = true
|
||||
end
|
||||
|
||||
--- setup the ui
|
||||
|
Reference in New Issue
Block a user