diff --git a/ghunt/apis/peoplepa.py b/ghunt/apis/peoplepa.py index 17ef9dc5..f1c21e11 100644 --- a/ghunt/apis/peoplepa.py +++ b/ghunt/apis/peoplepa.py @@ -9,6 +9,7 @@ from typing import * import inspect import json +import pprint class PeoplePaHttp(GAPI): @@ -113,10 +114,16 @@ async def people_lookup(self, as_client: httpx.AsyncClient, email: str, params_t # Parsing data = json.loads(req.text) + person = Person() if not data: return False, person + if "error" in data: + message = data["error"].get("message", "Erro desconhecido.") + gb.rc.print(f"[-] Request Error: {message}", style="deep_pink4") + return False, person + person_data = list(data["people"].values())[0] await person._scrape(as_client, person_data)