commit 849b08a014c82deeaac67ef168c33ed51542ad2c Author: Isis Lovecruft isis@torproject.org Date: Fri Nov 15 15:20:19 2013 +0000
Remove unnecessary config parameter coercion.
FORCE_PORTS and FORCE_FLAGS are already set to lists. We don't need to coerce them if they weren't set anymore. --- lib/bridgedb/Main.py | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/lib/bridgedb/Main.py b/lib/bridgedb/Main.py index ad51631..7dfd41f 100644 --- a/lib/bridgedb/Main.py +++ b/lib/bridgedb/Main.py @@ -370,14 +370,11 @@ def startup(options, rundir, configFile): logging.debug("Created splitter: %r" % splitter)
# Create ring parameters. - forcePorts = getattr(config, "FORCE_PORTS") - forceFlags = getattr(config, "FORCE_FLAGS") - if not forcePorts: forcePorts = [] - if not forceFlags: forceFlags = [] - ringParams=Bridges.BridgeRingParameters(needPorts=forcePorts, - needFlags=forceFlags) + ringParams = Bridges.BridgeRingParameters(needPorts=config.FORCE_PORTS, + needFlags=config.FORCE_FLAGS)
emailDistributor = ipDistributor = None + # As appropriate, create an IP-based distributor. if config.HTTPS_DIST and config.HTTPS_SHARE: logging.debug("Setting up HTTPS Distributor...")
tor-commits@lists.torproject.org