From 210bc5c28bc64db163e3a4dc9f725835cfa160c6 Mon Sep 17 00:00:00 2001 From: TheTaoOfSu Date: Fri, 24 May 2024 21:34:10 +0200 Subject: [PATCH] Finish fixing scope issue --- lua/telekasten/utils/files.lua | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lua/telekasten/utils/files.lua b/lua/telekasten/utils/files.lua index b4720da..3cf78c4 100644 --- a/lua/telekasten/utils/files.lua +++ b/lua/telekasten/utils/files.lua @@ -548,18 +548,18 @@ function M.Pinfo:resolve_link(title, opts) :gsub("^/", "") -- now suggest a template based on opts - self.template = M.note_type_templates.normal + self.template = opts.note_type_templates.normal if opts.template_handling == "prefer_new_note" then - self.template = M.note_type_templates.normal + self.template = opts.note_type_templates.normal elseif opts.template_handling == "always_ask" then self.template = nil elseif opts.template_handling == "smart" then if self.is_daily then - self.template = M.note_type_templates.daily + self.template = opts.note_type_templates.daily elseif self.is_weekly then - self.template = M.note_type_templates.weekly + self.template = opts.note_type_templates.weekly else - self.template = M.note_type_templates.normal + self.template = opts.note_type_templates.normal end end