aboutsummaryrefslogtreecommitdiffstats
path: root/mod/mitem.php
diff options
context:
space:
mode:
authorHaakon Meland Eriksen <haakon.eriksen@far.no>2015-09-11 06:42:11 +0200
committerHaakon Meland Eriksen <haakon.eriksen@far.no>2015-09-11 06:42:11 +0200
commitedb1473f13a87ccfdfe2555ac9ab798fbc073805 (patch)
tree18a15afbca3cdbbf262e0737d01e23e7b4905cf1 /mod/mitem.php
parent2f73d24ab134391c3b3a69d5cbfede42e028b5ed (diff)
parentf2171173fe2c9a0596672da293eb756a514ff789 (diff)
downloadvolse-hubzilla-edb1473f13a87ccfdfe2555ac9ab798fbc073805.tar.gz
volse-hubzilla-edb1473f13a87ccfdfe2555ac9ab798fbc073805.tar.bz2
volse-hubzilla-edb1473f13a87ccfdfe2555ac9ab798fbc073805.zip
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'mod/mitem.php')
-rw-r--r--mod/mitem.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/mod/mitem.php b/mod/mitem.php
index 0fadd1548..d6572bd56 100644
--- a/mod/mitem.php
+++ b/mod/mitem.php
@@ -64,6 +64,7 @@ function mitem_post(&$a) {
$_REQUEST['mitem_id'] = $mitem_id;
$r = menu_edit_item($_REQUEST['menu_id'],$uid,$_REQUEST);
if($r) {
+ menu_sync_packet($uid,get_observer_hash(),$_REQUEST['menu_id']);
//info( t('Menu element updated.') . EOL);
goaway(z_root() . '/mitem/' . $_REQUEST['menu_id'] . (($a->is_sys) ? '?f=&sys=1' : ''));
}
@@ -74,6 +75,7 @@ function mitem_post(&$a) {
else {
$r = menu_add_item($_REQUEST['menu_id'],$uid,$_REQUEST);
if($r) {
+ menu_sync_packet($uid,get_observer_hash(),$_REQUEST['menu_id']);
//info( t('Menu element added.') . EOL);
if($_REQUEST['submit']) {
goaway(z_root() . '/menu' . (($a->is_sys) ? '?f=&sys=1' : ''));
@@ -202,7 +204,9 @@ function mitem_content(&$a) {
$lockstate = (($mitem['allow_cid'] || $mitem['allow_gid'] || $mitem['deny_cid'] || $mitem['deny_gid']) ? 'lock' : 'unlock');
if(argc() == 4 && argv(3) == 'drop') {
+ menu_sync_packet($uid,get_observer_hash(),$mitem['mitem_menu_id']);
$r = menu_del_item($mitem['mitem_menu_id'], $uid, intval(argv(2)));
+ menu_sync_packet($uid,get_observer_hash(),$mitem['mitem_menu_id']);
if($r)
info( t('Menu item deleted.') . EOL);
else