From 1ae4c3019b4e72e6619de97c3de879f26367deb6 Mon Sep 17 00:00:00 2001 From: dmunozv04 <39565245+dmunozv04@users.noreply.github.com> Date: Mon, 10 Mar 2025 11:41:33 +0100 Subject: [PATCH] Rework conditions Fixes Chained comparison PYL-R1716 --- src/iSponsorBlockTV/main.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/iSponsorBlockTV/main.py b/src/iSponsorBlockTV/main.py index 5a056f4..f7cb347 100644 --- a/src/iSponsorBlockTV/main.py +++ b/src/iSponsorBlockTV/main.py @@ -101,10 +101,10 @@ class DeviceListener: next_segment = None for segment in segments: segment_start = segment["start"] + segment_end = segment["end"] is_within_start_range = ( - position < 1 - and segment_start <= position < segment["end"] - and segment["end"] > 1 + position < 1 < segment_end + and segment_start <= position < segment_end ) is_beyond_current_position = segment_start > position