From 1ab27e3cf8d6c1c8d212608360b8267a2ad5cb34 Mon Sep 17 00:00:00 2001 From: Martin Konecny Date: Wed, 15 May 2013 17:18:42 -0400 Subject: [PATCH] be more idiomatic --- python_apps/pypo/pypoliquidsoap.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/python_apps/pypo/pypoliquidsoap.py b/python_apps/pypo/pypoliquidsoap.py index 860049b24..50a47db94 100644 --- a/python_apps/pypo/pypoliquidsoap.py +++ b/python_apps/pypo/pypoliquidsoap.py @@ -159,7 +159,7 @@ class PypoLiquidsoap(): to_be_removed.update(liq_queue_ids - schedule_ids) to_be_added.update(schedule_ids - liq_queue_ids) - if len(to_be_removed): + if to_be_removed: self.logger.info("Need to remove items from Liquidsoap: %s" % \ to_be_removed) @@ -169,7 +169,7 @@ class PypoLiquidsoap(): if mi is not None and mi["row_id"] in to_be_removed: self.stop(i) - if len(to_be_added): + if to_be_added: self.logger.info("Need to add items to Liquidsoap *now*: %s" % \ to_be_added) @@ -180,7 +180,7 @@ class PypoLiquidsoap(): #handle webstreams current_stream_id = self.telnet_liquidsoap.get_current_stream_id() - if len(scheduled_now_webstream): + if scheduled_now_webstream: if current_stream_id != scheduled_now_webstream[0]: self.play(scheduled_now_webstream[0]) elif current_stream_id != "-1":