Skip to content

Commit

Permalink
youuuuuuutubedl: fix thread_pool minimum size
Browse files Browse the repository at this point in the history
  • Loading branch information
naisanzaa committed Apr 17, 2023
1 parent 605818e commit 575e703
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion automon/integrations/youuuuuuutubedl/thread.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,11 @@
class ThreadPool:

@staticmethod
def config_thread_pool(thread_pool: int) -> ThreadPoolExecutor:
def config_thread_pool(thread_pool: int = 1) -> ThreadPoolExecutor:
"""Configure threading pool
thread_pool: must be > 0
"""
if not thread_pool:
thread_pool = 1
return ThreadPoolExecutor(max_workers=thread_pool)

0 comments on commit 575e703

Please sign in to comment.