Skip to content

Commit

Permalink
Modify namedtuple access
Browse files Browse the repository at this point in the history
Access to the attributes of Enum was changed
from field name to index due to a known issue
on cpython as described in the following issue:

python/cpython#100098
  • Loading branch information
EONRaider committed Feb 1, 2023
1 parent 70d45ea commit 307869c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions reconlib/hackertarget/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,8 @@ def get_query_url(self, endpoint: HackerTarget, params: dict = None) -> str:
"""
return urlunparse(
(
HackerTarget.URL.value.scheme,
HackerTarget.URL.value.netloc,
HackerTarget.URL.value[0],
HackerTarget.URL.value[1],
f"{endpoint.value}/",
"",
urlencode(params) if params else "",
Expand Down
2 changes: 1 addition & 1 deletion reconlib/virustotal/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ def get_query_url(
"""
return urlunparse(
(
(url := VirusTotal.URL.value).scheme,
(url := VirusTotal.URL.value)[0],
url.netloc,
f"{url.path}/{endpoint.value.format(target)}",
"",
Expand Down

0 comments on commit 307869c

Please sign in to comment.