Browse Source

Handle & symbols correctly in tag values

master
Pekka Helenius 4 years ago
parent
commit
750ad03dfe
1 changed files with 1 additions and 0 deletions
  1. +1
    -0
      pysitemap/base_crawler.py

+ 1
- 0
pysitemap/base_crawler.py View File

@ -183,6 +183,7 @@ class Crawler:
key = arg[0] key = arg[0]
# Remove leading and trailing quote marks from value # Remove leading and trailing quote marks from value
value = re.sub(r'^["\']?(.*?)["\']?$', '\\1', arg[1]) value = re.sub(r'^["\']?(.*?)["\']?$', '\\1', arg[1])
value = re.sub(r'&', '&', value)
for field in fields: for field in fields:
if key == field: if key == field:


Loading…
Cancel
Save