[rhythmbox] artsearch: don't use the lookup key for storage (bug #667778)
- From: Jonathan Matthew <jmatthew src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [rhythmbox] artsearch: don't use the lookup key for storage (bug #667778)
- Date: Fri, 13 Jan 2012 14:44:17 +0000 (UTC)
commit 39360ed8e3e944e8f82973d619b33ee5e3c53051
Author: Jonathan Matthew <jonathan d14n org>
Date: Sat Jan 14 00:05:41 2012 +1000
artsearch: don't use the lookup key for storage (bug #667778)
also add an assert to make sure I don't do this again.
metadata/rb-ext-db.c | 1 +
plugins/artsearch/artsearch.py | 4 +++-
2 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/metadata/rb-ext-db.c b/metadata/rb-ext-db.c
index d558d3e..0ffc907 100644
--- a/metadata/rb-ext-db.c
+++ b/metadata/rb-ext-db.c
@@ -160,6 +160,7 @@ create_store_request (RBExtDBKey *key,
GValue *value)
{
RBExtDBStoreRequest *sreq = g_slice_new0 (RBExtDBStoreRequest);
+ g_assert (rb_ext_db_key_is_lookup (key) == FALSE);
sreq->key = rb_ext_db_key_copy (key);
sreq->source_type = source_type;
if (uri != NULL) {
diff --git a/plugins/artsearch/artsearch.py b/plugins/artsearch/artsearch.py
index d8d5304..3ded61b 100644
--- a/plugins/artsearch/artsearch.py
+++ b/plugins/artsearch/artsearch.py
@@ -43,7 +43,9 @@ class Search(object):
def next_search(self):
if len(self.searches) == 0:
- self.store.store(self.key, RB.ExtDBSourceType.NONE, None)
+ key = RB.ExtDBKey.create_storage("album", self.key.get_field("album"))
+ key.add_field("artist", self.key.get_field("artist"))
+ self.store.store(key, RB.ExtDBSourceType.NONE, None)
return False
search = self.searches.pop(0)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]