aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--plugins/lfautoinsert.lua1
1 files changed, 1 insertions, 0 deletions
diff --git a/plugins/lfautoinsert.lua b/plugins/lfautoinsert.lua
index 5f4148b..a156964 100644
--- a/plugins/lfautoinsert.lua
+++ b/plugins/lfautoinsert.lua
@@ -41,6 +41,7 @@ config.plugins.lfautoinsert = { map = {
local function get_autoinsert_map(filename)
local map = {}
+ if not filename then return map end
for pattern, closing in pairs(config.plugins.lfautoinsert.map) do
if type(closing) == "table" then
if common.match_pattern(filename, closing.file_patterns) then