aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/bookmarks.php8
1 files changed, 3 insertions, 5 deletions
diff --git a/include/bookmarks.php b/include/bookmarks.php
index 3a4c5c5d6..7a9f40697 100644
--- a/include/bookmarks.php
+++ b/include/bookmarks.php
@@ -7,10 +7,6 @@ function bookmark_add($channel,$sender,$taxonomy,$private) {
$iarr = array();
$channel_id = $channel['channel_id'];
-
-
-
-
if($private)
$iarr['contact_allow'] = array($channel['channel_hash']);
$iarr['mitem_link'] = $taxonomy['url'];
@@ -45,12 +41,14 @@ function bookmark_add($channel,$sender,$taxonomy,$private) {
logger('bookmark_add: unable to create menu ' . $arr['menu_name']);
return;
}
-
+ logger('add_bookmark: menu_id ' . $menu_id);
$r = q("select * from menu_item where mitem_link = '%s' and mitem_menu_id = %d and mitem_channel_id = %d limit 1",
dbesc($iarr['mitem_link']),
intval($menu_id),
intval($channel_id)
);
+ if($r)
+ logger('duplicate menu entry');
if(! $r)
$r = menu_add_item($menu_id,$channel_id,$iarr);
return $r;