diff options
| author | Chris <[email protected]> | 2021-07-06 20:42:29 -0400 | 
|---|---|---|
| committer | Chris <[email protected]> | 2021-07-06 20:42:29 -0400 | 
| commit | 716f127e95b71bdc1f1ebb960b381ba50b10c1fe (patch) | |
| tree | 0683b852e4f54cfeaf98c206f9049e4ee130ddbb /lua/lv-autopairs | |
| parent | 0e2ad0c1fec50a24177129c89b3edb9007776caf (diff) | |
wrap requires in pcall
Diffstat (limited to 'lua/lv-autopairs')
| -rw-r--r-- | lua/lv-autopairs/init.lua | 4 | 
1 files changed, 4 insertions, 0 deletions
| diff --git a/lua/lv-autopairs/init.lua b/lua/lv-autopairs/init.lua index 6a9e4286..b8dad5f3 100644 --- a/lua/lv-autopairs/init.lua +++ b/lua/lv-autopairs/init.lua @@ -1,6 +1,10 @@  -- if not package.loaded['nvim-autopairs'] then  --   return  -- end +local status_ok, autopairs = pcall(require, "nvim-autopairs") +if not status_ok then +  return +end  local npairs = require "nvim-autopairs"  local Rule = require "nvim-autopairs.rule" | 
