fix: previewer for builtin.builtin (#1583)
This commit is contained in:
@@ -563,7 +563,7 @@ previewers.builtin = defaulter(function(_)
|
|||||||
end,
|
end,
|
||||||
|
|
||||||
define_preview = function(self, entry, status)
|
define_preview = function(self, entry, status)
|
||||||
local module_name = vim.fn.fnamemodify(entry.filename, ":t:r")
|
local module_name = vim.fn.fnamemodify(vim.fn.fnamemodify(entry.filename, ":h"), ":t")
|
||||||
local text
|
local text
|
||||||
if entry.text:sub(1, #module_name) ~= module_name then
|
if entry.text:sub(1, #module_name) ~= module_name then
|
||||||
text = module_name .. "." .. entry.text
|
text = module_name .. "." .. entry.text
|
||||||
|
|||||||
Reference in New Issue
Block a user