Skip to content
Snippets Groups Projects
Commit 1a260e89 authored by Greg Wilson's avatar Greg Wilson
Browse files

Merge pull request #81 from r-gaia-cs/fix-glossary

Make filter for id at definitions general
parents 225e7366 fc06f3dd
Branches
Tags
No related merge requests found
......@@ -24,12 +24,11 @@ def keyword2html(keyword_node):
def id4glossary(key, value, format, meta):
"""Add id to keywords at glossary."""
if "subtitle" in meta and pf.stringify(meta['subtitle']) == 'Reference':
if key == "DefinitionList":
for definition in value:
definition[0] = keyword2html(definition[0])
return {"t": key,
"c": value}
if key == "DefinitionList":
for definition in value:
definition[0] = keyword2html(definition[0])
return {"t": key,
"c": value}
if __name__ == '__main__':
pf.toJSONFilter(id4glossary)
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment