diff --git a/src/resources/filters/ast/customnodes.lua b/src/resources/filters/ast/customnodes.lua index 0727f64d85f..a36bf6a3a09 100644 --- a/src/resources/filters/ast/customnodes.lua +++ b/src/resources/filters/ast/customnodes.lua @@ -249,42 +249,6 @@ function create_emulated_node(t, tbl, context, forwarder) return result, custom_node_data[id] end --- walk_meta walks a Pandoc Meta object, applying the filter to each node --- and recursing on lists and objects. It mutates the meta object in place --- and returns it. --- --- It performs slightly more work than a regular walk filter because of the --- ambiguity around single-element lists and objects. -function walk_meta(meta, filter) - local skip = { - ["nil"] = true, - number = true, - boolean = true, - string = true, - ["function"] = true, - } - local iterate = { - Meta = true, - List = true, - } - local function walk(obj) - local t = type(obj) - if skip[t] then - return obj - end - local pt = quarto.utils.type(obj) - if iterate[pt] then - for k, v in pairs(obj) do - obj[k] = walk(v) - end - else - return _quarto.ast.walk(obj, filter) - end - return obj - end - return walk(meta) -end - _quarto.ast = { vault = { _uuid = "3ade8a4a-fb1d-4a6c-8409-ac45482d5fc9", @@ -541,8 +505,6 @@ _quarto.ast = { walk = run_emulated_filter, - walk_meta = walk_meta, - writer_walk = function(doc, filter) local old_custom_walk = filter.Custom local function custom_walk(node) diff --git a/src/resources/filters/normalize/extractquartodom.lua b/src/resources/filters/normalize/extractquartodom.lua index 2575585690e..f562adc5711 100644 --- a/src/resources/filters/normalize/extractquartodom.lua +++ b/src/resources/filters/normalize/extractquartodom.lua @@ -49,11 +49,6 @@ function parse_md_in_html_rawblocks() end return result end, - -- Meta = function(meta) - -- local filter = parse_md_in_html_rawblocks() - -- local result = _quarto.ast.walk_meta(meta, filter) - -- return result - -- end, } end