Skip to content

Commit

Permalink
Update namespace registration
Browse files Browse the repository at this point in the history
  • Loading branch information
webb-ben committed Jan 17, 2024
1 parent b8fcdbe commit 0aac3ba
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion sitemap_generator/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,11 +59,12 @@
<lastmod>{}</lastmod>
</url>
'''
ET.register_namespace('', 'http://www.sitemaps.org/schemas/sitemap/0.9')


def write_tree(tree, file):
ET.register_namespace('', 'http://www.sitemaps.org/schemas/sitemap/0.9')
tree.write(file, **SITEMAP_ARGS)
ET._namespace_map.pop('http://www.sitemaps.org/schemas/sitemap/0.9')


def get_smi():
Expand Down

0 comments on commit 0aac3ba

Please sign in to comment.