HTTP Fetcher code improvements

pull/540/head
dgtlmoon 2022-04-12 08:36:08 +02:00 zatwierdzone przez GitHub
rodzic 4074fe53f1
commit 34a87c0f41
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
1 zmienionych plików z 122 dodań i 124 usunięć

Wyświetl plik

@ -46,9 +46,6 @@ class perform_site_check():
if 'Accept-Encoding' in request_headers and "br" in request_headers['Accept-Encoding']:
request_headers['Accept-Encoding'] = request_headers['Accept-Encoding'].replace(', br', '')
# @todo check the failures are really handled how we expect
else:
timeout = self.datastore.data['settings']['requests']['timeout']
url = self.datastore.get_val(uuid, 'url')
request_body = self.datastore.get_val(uuid, 'body')
@ -124,6 +121,7 @@ class perform_site_check():
"application"].get(
"render_anchor_tag_content", False)
)
# Re #340 - return the content before the 'ignore text' was applied
text_content_before_ignored_filter = stripped_text_from_html.encode('utf-8')