aboutsummaryrefslogtreecommitdiffstats
path: root/lua/conform/formatters/markdown-toc.lua
diff options
context:
space:
mode:
Diffstat (limited to 'lua/conform/formatters/markdown-toc.lua')
-rw-r--r--lua/conform/formatters/markdown-toc.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/lua/conform/formatters/markdown-toc.lua b/lua/conform/formatters/markdown-toc.lua
index a7a9694..5e1d80a 100644
--- a/lua/conform/formatters/markdown-toc.lua
+++ b/lua/conform/formatters/markdown-toc.lua
@@ -6,10 +6,10 @@ return {
},
command = "markdown-toc",
stdin = false,
- args = function(self, ctx)
+ args = function(_, ctx)
-- use the indentation set in the current buffer, effectively allowing us to
-- use values from .editorconfig
- local indent = vim.bo[ctx.buf].expandtab and (" "):rep(vim.bo[ctx.buf].tabstop) or "\t"
+ local indent = vim.bo[ctx.buf].expandtab and (" "):rep(ctx.shiftwidth) or "\t"
return { "--indent=" .. indent, "-i", "$FILENAME" }
end,
}