Skip to content

Commit

Permalink
fix(plugins): pass the correct configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
vyfor committed Jan 31, 2025
1 parent 8580bb3 commit 7875026
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lua/cord/api/plugin.lua
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,13 @@ function M.init()

if type(ty) == 'number' then
name = def
cfg = plugin
logger.debug('Loading plugin: ' .. name)
local ok, mod = pcall(require, name)
if not ok then return 'Failed to load plugin \'' .. name .. '\': ' .. mod end
plugin = mod
elseif type(ty) == 'string' and type(def) == 'table' then
name = ty
cfg = def
logger.debug('Loading plugin with config: ' .. name)
local ok, mod = pcall(require, name)
if not ok then return 'Failed to load plugin \'' .. name .. '\': ' .. mod end
Expand Down

0 comments on commit 7875026

Please sign in to comment.