Skip to content

Commit

Permalink
fix: escape todo pattern *before* joining special char
Browse files Browse the repository at this point in the history
  • Loading branch information
aarondill committed Aug 10, 2024
1 parent 189edf2 commit 90525d0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ftdetect/todo.lua
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ end
--- Creates a skeleton for new files
local setup_todos = vim.schedule_wrap(function(path) ---@param path string
local group = vim.api.nvim_create_augroup("todos", { clear = true })
local pattern = pattern_escape(vim.fs.joinpath(path, "*"))
local pattern = vim.fs.joinpath(pattern_escape(path), "*")

create_autocmd({ "BufRead", "BufNewFile" }, handle_todo, { group = group, pattern = pattern })

Expand Down

0 comments on commit 90525d0

Please sign in to comment.