mirror of
https://github.com/mxrch/GHunt.git
synced 2026-10-17 04:41:03 +08:00
fixed bug when gaia id is incorrect
This commit is contained in:
@@ -161,7 +161,7 @@ class PeoplePaHttp(HttpAPI):
|
||||
# Parsing
|
||||
data = json.loads(req.text)
|
||||
person = Person()
|
||||
if not data:
|
||||
if data["personResponse"][0]["status"] == "NOT_FOUND":
|
||||
return False, person
|
||||
|
||||
person_data = data["personResponse"][0]["person"]
|
||||
|
||||
@@ -20,7 +20,7 @@ async def hunt(as_client: httpx.AsyncClient, email_address: str):
|
||||
is_found, target = await people_pa.people_lookup(as_client, email_address, params_template="max_details")
|
||||
if not is_found:
|
||||
await as_client.aclose()
|
||||
exit("[-] The target wasn't found.")
|
||||
exit("\n[-] The target wasn't found.")
|
||||
|
||||
containers = target.sourceIds
|
||||
for container in containers:
|
||||
|
||||
@@ -19,7 +19,7 @@ async def hunt(as_client: httpx.AsyncClient, gaia_id: str):
|
||||
is_found, target = await people_pa.people(as_client, gaia_id, params_template="max_details")
|
||||
if not is_found:
|
||||
await as_client.aclose()
|
||||
exit("[-] The target wasn't found.")
|
||||
exit("\n[-] The target wasn't found.")
|
||||
|
||||
containers = target.sourceIds
|
||||
for container in containers:
|
||||
|
||||
Reference in New Issue
Block a user