diff options
author | pukkandan <pukkandan.ytdlp@gmail.com> | 2021-09-24 02:16:03 +0530 |
---|---|---|
committer | pukkandan <pukkandan.ytdlp@gmail.com> | 2021-09-24 05:14:16 +0530 |
commit | 1813a6ccd4928f81ca5f4c0144c0008f404d67dd (patch) | |
tree | 8928a4744a879ebde74cbadc25f655bb9d86e3e7 /yt_dlp/extractor/common.py | |
parent | 8100c77223d100e91fdc427e28dc39fc9753944e (diff) | |
download | hypervideo-pre-1813a6ccd4928f81ca5f4c0144c0008f404d67dd.tar.lz hypervideo-pre-1813a6ccd4928f81ca5f4c0144c0008f404d67dd.tar.xz hypervideo-pre-1813a6ccd4928f81ca5f4c0144c0008f404d67dd.zip |
[youtube] Fix `--mark-watched` with `--cookies-from-browser`
Closes #1019
Diffstat (limited to 'yt_dlp/extractor/common.py')
-rw-r--r-- | yt_dlp/extractor/common.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/yt_dlp/extractor/common.py b/yt_dlp/extractor/common.py index ae03c1bab..4797e8e2d 100644 --- a/yt_dlp/extractor/common.py +++ b/yt_dlp/extractor/common.py @@ -3503,9 +3503,11 @@ class InfoExtractor(object): raise NotImplementedError('This method must be implemented by subclasses') def mark_watched(self, *args, **kwargs): - if (self.get_param('mark_watched', False) - and (self._get_login_info()[0] is not None - or self.get_param('cookiefile') is not None)): + if not self.get_param('mark_watched', False): + return + if (self._get_login_info()[0] is not None + or self.get_param('cookiefile') + or self.get_param('cookiesfrombrowser')): self._mark_watched(*args, **kwargs) def _mark_watched(self, *args, **kwargs): |