diff options
author | Steven Arcangeli <stevearc@stevearc.com> | 2024-04-23 07:20:29 -0700 |
---|---|---|
committer | Steven Arcangeli <stevearc@stevearc.com> | 2024-04-23 07:20:54 -0700 |
commit | 7a205c944d228ca0a5ec67656f59d20ba11ccca2 (patch) | |
tree | ef712db0a785ba423a2f6ae4eee86045668fb8c7 /lua/conform/util.lua | |
parent | a6965ac128eba75537ec2bc5ddd5d5e357062bdc (diff) |
fix: refactor deprecated methods in neovim 0.10
Diffstat (limited to 'lua/conform/util.lua')
-rw-r--r-- | lua/conform/util.lua | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/lua/conform/util.lua b/lua/conform/util.lua index e967918..950bdae 100644 --- a/lua/conform/util.lua +++ b/lua/conform/util.lua @@ -133,11 +133,15 @@ M.extend_args = function(args, extra_args, opts) if type(extra_args) == "string" then error("extra_args must be a table when args is a table") end + local ret = {} if opts.append then - return vim.tbl_flatten({ args, extra_args }) + vim.list_extend(ret, args) + vim.list_extend(ret, extra_args) else - return vim.tbl_flatten({ extra_args, args }) + vim.list_extend(ret, extra_args) + vim.list_extend(ret, args) end + return ret end end end |