From 48950f65dee577f178c1e3b8167fbdec4991c8c7 Mon Sep 17 00:00:00 2001 From: Vhyrro Date: Fri, 5 Jan 2024 22:14:13 +0100 Subject: [PATCH] chore(neorg/core/lib): fix errors with `lib.mod` --- lua/neorg/core/lib.lua | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lua/neorg/core/lib.lua b/lua/neorg/core/lib.lua index 0af14fd00d..91111c6aed 100644 --- a/lua/neorg/core/lib.lua +++ b/lua/neorg/core/lib.lua @@ -467,6 +467,8 @@ function lib.lazy_copy(to_copy) }) end +lib.mod = {} + --- Wrapper function to add two values. --- This function only takes in one argument because the second value to add is provided as a parameter in the callback. --- @param amount number The number to add. @@ -487,6 +489,8 @@ function lib.mod.modify(to) end end +lib.mod.exclude = {} + function lib.mod.exclude.first(func, alt) return function(i, val) return i == 1 and (alt and alt(i, val) or val) or func(i, val)