Skip to content

Commit

Permalink
chore(lunamark): Avoid loading cosmo when not needed
Browse files Browse the repository at this point in the history
  • Loading branch information
Omikhleia authored and Didier Willis committed Aug 1, 2024
1 parent 5fbcb70 commit 0e55a4b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lua-libraries/lunamark/util.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
--- Utility functions for lunamark.

local M = {}
local cosmo = require("cosmo")
local rep = string.rep
local lpeg = require("lpeg")
local Cs, P, S, lpegmatch = lpeg.Cs, lpeg.P, lpeg.S, lpeg.match
Expand Down Expand Up @@ -49,6 +48,7 @@ end
-- it will be treated as an array with one element. If it is
-- `nil`, it will be treated as an empty array.
function M.sepby(arg)
local cosmo = require("cosmo") -- HACK OMIKHLEIA
local a = arg[1]
if not a then
a = {}
Expand Down

0 comments on commit 0e55a4b

Please sign in to comment.