From 0964201c18c15951001d468ed4a8ed5d5960aa17 Mon Sep 17 00:00:00 2001 From: Joerg Jaspert Date: Thu, 17 Feb 2011 20:25:48 +0100 Subject: [PATCH] fixup source_exist reverse the order of the map check make it a bit more readable Signed-off-by: Joerg Jaspert --- daklib/dbconn.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/daklib/dbconn.py b/daklib/dbconn.py index 67852949..e5db1644 100755 --- a/daklib/dbconn.py +++ b/daklib/dbconn.py @@ -2277,9 +2277,9 @@ def source_exists(source, source_version, suites = ["any"], session=None): maps = [ (x[1], x[2]) for x in maps if x[0] == "map" or x[0] == "silent-map" ] s = [suite] - for x in maps: - if x[1] in s and x[0] not in s: - s.append(x[0]) + for (from_, to) in maps: + if from_ in s and to not in s: + s.append(to) q = q.filter(DBSource.suites.any(Suite.suite_name.in_(s))) -- 2.39.5