diff --git a/redditbot.py b/redditbot.py index cdf3147..9b118ac 100644 --- a/redditbot.py +++ b/redditbot.py @@ -283,9 +283,9 @@ async def main(): for i in ('hls_url', 'dash_url'): if not ffmpeg_exists: continue - url = reddit_video.get(i) - if not url: + if not reddit_video.get(i): continue + url = reddit_video[i] print(url) proc = await asyncio.create_subprocess_exec('ffmpeg', '-nostdin', '-y', '-i', url, '-c', 'copy', '-f', 'mp4', filename) await proc.communicate()