From b4a252fba81f53631c07ca40ce7583f5d19a8a36 Mon Sep 17 00:00:00 2001 From: bashonly <88596187+bashonly@users.noreply.github.com> Date: Sat, 10 Jun 2023 17:49:12 -0500 Subject: [jsinterp] Fix division (#7279) * Fixes nsig decryption for Youtube JS player `8c7583ff` Authored by: bashonly --- yt_dlp/jsinterp.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'yt_dlp/jsinterp.py') diff --git a/yt_dlp/jsinterp.py b/yt_dlp/jsinterp.py index 7c7940efd..d6d555733 100644 --- a/yt_dlp/jsinterp.py +++ b/yt_dlp/jsinterp.py @@ -44,7 +44,7 @@ def _js_arith_op(op): def _js_div(a, b): - if JS_Undefined in (a, b) or not (a and b): + if JS_Undefined in (a, b) or not (a or b): return float('nan') return (a or 0) / b if b else float('inf') -- cgit v1.2.3