From 944a735c39a27fc86569c585f2805837b61adb60 Mon Sep 17 00:00:00 2001 From: Volpeon Date: Tue, 2 Aug 2022 20:56:45 +0200 Subject: Slightly tidied up metadata handling --- filters/lib/common.lua | 26 +------------------------- 1 file changed, 1 insertion(+), 25 deletions(-) (limited to 'filters/lib') diff --git a/filters/lib/common.lua b/filters/lib/common.lua index 4d44ff3..d6f92e0 100644 --- a/filters/lib/common.lua +++ b/filters/lib/common.lua @@ -12,30 +12,6 @@ function wide(el) return els end -function dump(o) - if type(o) == 'table' then - local s = '{ ' - for k, v in pairs(o) do - if type(k) ~= 'number' then k = '"' .. k .. '"' end - s = s .. '[' .. k .. '] = ' .. dump(v) .. ',' - end - return s .. '} ' - else - return tostring(o) - end -end - -function string.split(str, sep) - sep = sep or '%s' - - local parts = pandoc.List() - - for field, s in str:gmatch("([^" .. sep .. "]*)(" .. sep .. "?)") do - parts:insert(field) - if s == "" then return parts end - end -end - return { - wide = wide, dump = dump + wide = wide } -- cgit v1.2.3-70-g09d2