From 6ba32713ada1c290aa8ff0cfcf69c3cbb14d59d4 Mon Sep 17 00:00:00 2001 From: anondeveg Date: Thu, 26 Feb 2026 04:55:05 +0200 Subject: feat(secure): allow 'path' parameter for trust action 'allow' (#38001) --- runtime/lua/vim/secure.lua | 5 ----- 1 file changed, 5 deletions(-) (limited to 'runtime/lua/vim/secure.lua') diff --git a/runtime/lua/vim/secure.lua b/runtime/lua/vim/secure.lua index a2884f84dc..784b4d5ff0 100644 --- a/runtime/lua/vim/secure.lua +++ b/runtime/lua/vim/secure.lua @@ -168,7 +168,6 @@ end --- @field action 'allow'|'deny'|'remove' --- --- Path to a file to update. Mutually exclusive with {bufnr}. ---- Cannot be used when {action} is "allow". --- @field path? string --- Buffer number to update. Mutually exclusive with {path}. --- @field bufnr? integer @@ -195,10 +194,6 @@ function M.trust(opts) assert(not path or not bufnr, '"path" and "bufnr" are mutually exclusive') - if action == 'allow' then - assert(not path, '"path" is not valid when action is "allow"') - end - local fullpath ---@type string? if path then fullpath = vim.uv.fs_realpath(vim.fs.normalize(path)) -- cgit