Skip to content

Commit

Permalink
fix bug hackdaddy
Browse files Browse the repository at this point in the history
  • Loading branch information
boringthegod committed May 16, 2023
1 parent fd7ce3a commit b3ae8e7
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion postmaniac/postmaniac.py
Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,8 @@ def progress_bar(n, message=''):
urlsubord = "https://www.postman.com/_api/folder/" + owner + "-" + orde
responsesub = requests.get(urlsubord, headers=headers)
subcollection = responsesub.json()
if 'error' in subcollection:
continue
suborder = subcollection['data']['order']
subsubfolders = subcollection['data']['folders_order']
if len(subsubfolders) != 0:
Expand Down Expand Up @@ -304,6 +306,7 @@ def find_croustillant(datacr):
for request in order:
urlrequestfull = urlrequest + owner + "-" + request
requestresponse = requests.get(urlrequestfull, headers=headers)

requestresp = requestresponse.json()
urlreq = requestresp['data']['url']
auth = requestresp['data']['auth']
Expand Down Expand Up @@ -340,7 +343,8 @@ def find_croustillant(datacr):
pass
except json.JSONDecodeError as e:
continue
if datamode == "params" and len(requestresp['data']["data"]) > 0:
if datamode == "params" and requestresp['data']['data'] is not None and len(
requestresp['data']["data"]) > 0:

datas = requestresp['data']["data"]
for nom in datas:
Expand Down

0 comments on commit b3ae8e7

Please sign in to comment.