From e75a735a5cfe5f0c43315a9156e943277bf1e612 Mon Sep 17 00:00:00 2001 From: Jon Bergli Heier Date: Wed, 24 Aug 2011 14:33:58 +0200 Subject: Fixed join order in Track.search(). --- db.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'db.py') diff --git a/db.py b/db.py index d71a717..1295a89 100644 --- a/db.py +++ b/db.py @@ -133,7 +133,7 @@ class Track(Base): def search(session, *args, **kwargs): r = session.query(Track) s_or = [] - for f, n in ((Artist, 'artist'), (Track, 'title'), (Album, 'album')): + for f, n in ((Track, 'title'), (Album, 'album'), (Artist, 'artist')): if f != Track: r = r.join(f) if n in kwargs: -- cgit v1.2.3