mirror of
https://github.com/yt-dlp/yt-dlp
synced 2025-12-17 06:35:42 +07:00
[cleanup] Misc cleanup
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import functools
|
||||
from threading import Lock
|
||||
from .utils import supports_terminal_sequences, TERMINAL_SEQUENCES
|
||||
|
||||
@@ -49,6 +50,7 @@ def __init__(self, stream=None, lines=1, preserve_output=True):
|
||||
self._HAVE_FULLCAP = supports_terminal_sequences(self.stream)
|
||||
|
||||
def lock(func):
|
||||
@functools.wraps(func)
|
||||
def wrapper(self, *args, **kwargs):
|
||||
with self._movelock:
|
||||
return func(self, *args, **kwargs)
|
||||
|
||||
Reference in New Issue
Block a user