Skip to content

Commit

Permalink
fix flake8 liniting
Browse files Browse the repository at this point in the history
  • Loading branch information
subho007 committed Dec 28, 2023
1 parent a79228f commit c99f368
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions postmanparser/collection.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,16 +26,16 @@ class Collection:
info: Info = field(init=False)
item: List[Union[Item, ItemGroup]] = field(init=False)
event: List[Event] = None

def hasCollectionWrapper(self, data):
return "collection" in data

def validate(self, data):
if self.hasCollectionWrapper(data):
if "info" not in data["collection"] or "item" not in data["collection"]:
raise MissingRequiredFieldException(
"Invalid API Postman collection: Required 'info' and 'item' "
"properties in 'collection' object"
"Invalid API Postman collection: Required 'info' and 'item' "
"properties in 'collection' object"
)
else:
if "info" not in data or "item" not in data:
Expand Down Expand Up @@ -65,7 +65,7 @@ def parse_from_file(self, file_path):
self.validate(data)
self.parse(data)

def parse_from_url(self, url, key = None):
def parse_from_url(self, url, key=None):
response = None
headers = None
if key is not None:
Expand Down

0 comments on commit c99f368

Please sign in to comment.