fix(editorconfig): syntax error regression

This commit is contained in:
Lewis Russell 2024-03-11 09:47:26 +00:00 committed by Lewis Russell
parent f879a65455
commit cdbc3e3f3e

View File

@ -273,6 +273,9 @@ end
local M = {} local M = {}
-- Exposed for use in syntax/editorconfig.vim`
M.properties = properties
--- @private --- @private
--- Configure the given buffer with options from an `.editorconfig` file --- Configure the given buffer with options from an `.editorconfig` file
--- @param bufnr integer Buffer number to configure --- @param bufnr integer Buffer number to configure
@ -303,7 +306,7 @@ function M.config(bufnr)
local applied = {} --- @type table<string,string|boolean> local applied = {} --- @type table<string,string|boolean>
for opt, val in pairs(opts) do for opt, val in pairs(opts) do
if val ~= 'unset' then if val ~= 'unset' then
local func = properties[opt] local func = M.properties[opt]
if func then if func then
--- @type boolean, string? --- @type boolean, string?
local ok, err = pcall(func, bufnr, val, opts) local ok, err = pcall(func, bufnr, val, opts)