diff --git a/html5lib/sanitizer.py b/html5lib/sanitizer.py index 469d9b40..5ea20e96 100644 --- a/html5lib/sanitizer.py +++ b/html5lib/sanitizer.py @@ -182,9 +182,7 @@ def allowed_token(self, token, token_type): attrs = dict([(name, val) for name, val in token["data"][::-1] if name in self.allowed_attributes]) - for attr in self.attr_val_is_uri: - if attr not in attrs: - continue + for attr in set(attrs.keys()).intersection(set(self.attr_val_is_uri)): val_unescaped = re.sub("[`\000-\040\177-\240\s]+", '', unescape(attrs[attr])).lower() # remove replacement characters from unescaped characters pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy