diff --git a/lua/nvim-ts-autotag/internal.lua b/lua/nvim-ts-autotag/internal.lua index 420ea70..c9dae9e 100644 --- a/lua/nvim-ts-autotag/internal.lua +++ b/lua/nvim-ts-autotag/internal.lua @@ -389,7 +389,7 @@ local function rename_end_tag() end local function validate_rename() - local cursor = vim.api.nvim_win_get_cursor('.') + local cursor = vim.api.nvim_win_get_cursor(0) local line = vim.fn.getline(cursor[1]) local char = line:sub(cursor[2] + 1, cursor[2] + 1) -- only rename when last character is a word