From: Christian Dywan Date: Wed, 19 Jan 2011 20:34:39 +0000 (+0100) Subject: Fix invalid bookmark warning and move into insertion X-Git-Url: https://spindle.queued.net/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f0d2c49355317bc498277749a97c1aaa28871f9c;p=midori Fix invalid bookmark warning and move into insertion --- diff --git a/midori/main.c b/midori/main.c index cd0b2ef0..31276b01 100644 --- a/midori/main.c +++ b/midori/main.c @@ -494,9 +494,6 @@ midori_bookmarks_add_item_cb (KatzeArray* array, KatzeItem* item, sqlite3* db) { - g_return_if_fail (!katze_item_get_name (item) - && !katze_item_get_uri (item)); - midori_bookmarks_insert_item_db (db, item, katze_item_get_meta_string (item, "folder")); } diff --git a/panels/midori-bookmarks.c b/panels/midori-bookmarks.c index f059a7cd..3e0924f0 100644 --- a/panels/midori-bookmarks.c +++ b/panels/midori-bookmarks.c @@ -242,6 +242,9 @@ midori_bookmarks_insert_item_db (sqlite3* db, gchar* parent; gchar* uri; + g_return_if_fail (katze_item_get_name (item) + && katze_item_get_uri (item)); + if (KATZE_ITEM_IS_BOOKMARK (item)) uri = g_strdup (katze_item_get_uri (item)); else