fix(filetype): remove call to vim.fn.resolve and pass filename to match function

For example on MacOS, /etc/hostname.file is symlinked to
/private/etc/hostname.file. We only care about the original file path though.
This commit is contained in:
smjonas
2022-07-06 16:25:51 +02:00
parent f3c78a4465
commit f9683f2823
2 changed files with 2 additions and 2 deletions

View File

@@ -2408,7 +2408,7 @@ function M.match(args)
local ft, on_detect
-- First check for the simple case where the full path exists as a key
local path = vim.fn.resolve(vim.fn.fnamemodify(name, ':p'))
local path = vim.fn.fnamemodify(name, ':p')
ft, on_detect = dispatch(filename[path], path, bufnr)
if ft then
return ft, on_detect