mirror of
https://github.com/kevin1024/vcrpy.git
synced 2025-12-09 01:03:24 +00:00
Make hosts_to_ignore a set() earlier for clarity.
This commit is contained in:
@@ -211,12 +211,10 @@ class VCR(object):
|
|||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
hosts_to_ignore = list(ignore_hosts)
|
hosts_to_ignore = set(ignore_hosts)
|
||||||
if ignore_localhost:
|
if ignore_localhost:
|
||||||
hosts_to_ignore.extend(('localhost', '0.0.0.0', '127.0.0.1'))
|
hosts_to_ignore.update(('localhost', '0.0.0.0', '127.0.0.1'))
|
||||||
|
|
||||||
if hosts_to_ignore:
|
if hosts_to_ignore:
|
||||||
hosts_to_ignore = set(hosts_to_ignore)
|
|
||||||
filter_functions.append(self._build_ignore_hosts(hosts_to_ignore))
|
filter_functions.append(self._build_ignore_hosts(hosts_to_ignore))
|
||||||
|
|
||||||
if before_record_request:
|
if before_record_request:
|
||||||
|
|||||||
Reference in New Issue
Block a user