looks like chat has been neglected a bit recently

This commit is contained in:
redmatrix
2015-09-20 21:37:18 -07:00
parent 4fde0bf62e
commit d2565d0f61
6 changed files with 7 additions and 8 deletions

View File

@@ -91,7 +91,7 @@ function chatroom_destroy($channel,$arr) {
return $ret;
}
create_sync_packet($channel['channel_id'],array('chatroom' => $r));
build_sync_packet($channel['channel_id'],array('chatroom' => $r));
q("delete from chatroom where cr_id = %d",
intval($r[0]['cr_id'])

View File

@@ -94,9 +94,8 @@ EOT;
require_once('include/chat.php');
$has_chats = chatroom_list_count(local_channel());
if($has_chats) {
$nav['usermenu'][] = Array('chat/' . $channel['channel_address'],t('Chat'),"",t('Your chatrooms'),'chat_nav_btn');
}
$nav['usermenu'][] = Array('chat/' . $channel['channel_address'] . (($has_chats) ? '' : '/new'), t('Chat'),"",t('Your chatrooms'),'chat_nav_btn');
require_once('include/menu.php');
$has_bookmarks = menu_list_count(local_channel(),'',MENU_BOOKMARK) + menu_list_count(local_channel(),'',MENU_SYSTEM|MENU_BOOKMARK);