refactor(nvim): simplify std_condition
for statuscolumn
This commit is contained in:
parent
01c16211ed
commit
d6a21aac2b
@ -25,15 +25,7 @@ return {
|
||||
})
|
||||
|
||||
local std_condition = function(args)
|
||||
local buf_opt = function(option_name)
|
||||
local value = vim.api.nvim_get_option_value(option_name, { buf = args.buf })
|
||||
if value == "" then
|
||||
return nil
|
||||
else
|
||||
return value
|
||||
end
|
||||
end
|
||||
return (not buf_opt("bufhidden"))
|
||||
return #vim.api.nvim_get_option_value("bufhidden", { buf = args.buf }) == 0
|
||||
end
|
||||
|
||||
return {
|
||||
|
Loading…
Reference in New Issue
Block a user