Meta: Download resources referenced in action attributes of forms

Resources referenced in the action attribute of forms now also get
downloaded by the WPT import script.
This commit is contained in:
Glenn Skrzypczak 2025-07-24 18:22:49 +02:00 committed by Tim Ledbetter
parent 50fed1d65c
commit c5fc4a5ac2

View File

@ -89,6 +89,10 @@ class LinkedResourceFinder(HTMLParser):
attr_dict = dict(attrs)
if "rel" in attr_dict and attr_dict["rel"] == "stylesheet":
self._resources.append(attr_dict["href"])
if tag == "form":
attr_dict = dict(attrs)
if "action" in attr_dict:
self._resources.append(attr_dict["action"])
def handle_endtag(self, tag):
self._tag_stack_.pop()