mirror of
https://git.vectorsigma.ru/public/tubearchivist.git
synced 2026-08-05 05:29:27 +00:00
fix empty is_pending
This commit is contained in:
@@ -34,6 +34,9 @@ class TaskManager:
|
||||
def is_pending(self, task):
|
||||
"""check if task_name is pending, pass task object"""
|
||||
tasks = self.get_tasks_by_name(task.name)
|
||||
if not tasks:
|
||||
return False
|
||||
|
||||
return bool([i for i in tasks if i.get("status") == "PENDING"])
|
||||
|
||||
def get_pending(self, task_name):
|
||||
|
||||
Reference in New Issue
Block a user