Skip to content

Commit

Permalink
Refactored to snake case
Browse files Browse the repository at this point in the history
  • Loading branch information
campb303 committed Jun 21, 2021
1 parent 840931c commit e85592b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/webqueue2api/parser/queue.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@ def get_items(self) -> list:
for item in os.listdir(self.path):
item_path = Path(self.path, item)

isFile = True if os.path.isfile(item_path) else False
is_file = True if os.path.isfile(item_path) else False

if isFile and is_valid_item_name(item):
if is_file and is_valid_item_name(item):
items.append(Item(self.name, item))

return items
Expand Down Expand Up @@ -96,8 +96,8 @@ def is_valid_item_name(name: str) -> bool:
Returns:
bool: Name is valid item name.
"""
itemPattern = re.compile("^[0123456789]{1,3}$")
return True if itemPattern.match(name) else False
item_pattern = re.compile("^[0123456789]{1,3}$")
return True if item_pattern.match(name) else False

def get_valid_queues() -> list:
"""Returns a list of queues on the filesystem excluding ignored queues.
Expand Down

0 comments on commit e85592b

Please sign in to comment.