From d80576fec112a7d7c710de059dbd61bf7a5ee996 Mon Sep 17 00:00:00 2001 From: Adrian Sampson Date: Thu, 29 Aug 2013 17:07:04 -0700 Subject: [PATCH] get rid of dictionary comprehensions for Python 2.6 compatibility --- beets/library.py | 4 +++- beetsplug/mbsync.py | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/beets/library.py b/beets/library.py index ef6f86e85..e48b632d8 100644 --- a/beets/library.py +++ b/beets/library.py @@ -955,7 +955,9 @@ class Results(object): (row['id'],) ) values = dict(row) - values.update({row['key']: row['value'] for row in flex_rows}) + values.update( + dict((row['key'], row['value']) for row in flex_rows) + ) # Construct the Python object and yield it if it passes the # predicate. diff --git a/beetsplug/mbsync.py b/beetsplug/mbsync.py index 4ffe9a02e..2e8dd380e 100644 --- a/beetsplug/mbsync.py +++ b/beetsplug/mbsync.py @@ -93,7 +93,7 @@ def mbsync_albums(lib, query, move, pretend, write): continue items = list(a.items()) - old_data = {item: dict(item) for item in items} + old_data = dict((item, dict(item)) for item in items) # Get the MusicBrainz album information. album_info = hooks.album_for_mbid(a.mb_albumid)