From be14634c5f585b46883ffc6befe8f0d1bc285d70 Mon Sep 17 00:00:00 2001 From: Mikael Nordfeldth Date: Sun, 11 May 2014 21:05:25 +0200 Subject: [PATCH] ConversationRepliesAction removed, Conversation is enough --- actions/conversationreplies.php | 86 --------------------------------- lib/router.php | 3 -- lib/threadednoticelist.php | 2 +- 3 files changed, 1 insertion(+), 90 deletions(-) delete mode 100644 actions/conversationreplies.php diff --git a/actions/conversationreplies.php b/actions/conversationreplies.php deleted file mode 100644 index 49c806fa98..0000000000 --- a/actions/conversationreplies.php +++ /dev/null @@ -1,86 +0,0 @@ - - * @license http://www.fsf.org/licensing/licenses/agpl.html AGPLv3 - * @link http://status.net/ - * - * StatusNet - the distributed open-source microblogging tool - * Copyright (C) 2009, StatusNet, Inc. - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Affero General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Affero General Public License for more details. - * - * You should have received a copy of the GNU Affero General Public License - * along with this program. If not, see . - */ - -if (!defined('STATUSNET') && !defined('LACONICA')) { - exit(1); -} - -// XXX: not sure how to do paging yet, -// so set a 60-notice limit - -require_once INSTALLDIR.'/lib/noticelist.php'; - -/** - * Conversation tree in the browser - * - * @category Action - * @package StatusNet - * @author Evan Prodromou - * @license http://www.fsf.org/licensing/licenses/agpl.html AGPLv3 - * @link http://status.net/ - */ -class ConversationRepliesAction extends ConversationAction -{ - function handle($args) - { - if ($this->boolean('ajax')) { - $this->showAjax(); - } else { - parent::handle($args); - } - } - - /** - * Show content. - * - * Display a hierarchical unordered list in the content area. - * Uses ConversationTree to do most of the heavy lifting. - * - * @return void - */ - function showContent() - { - $ct = new FullThreadedNoticeList($this->notices, $this, $this->userProfile); - - $cnt = $ct->show(); - } - - function showAjax() - { - $this->startHTML('text/xml;charset=utf-8'); - $this->elementStart('head'); - // TRANS: Title for conversation page. - $this->element('title', null, _m('TITLE','Notice')); - $this->elementEnd('head'); - $this->elementStart('body'); - $this->showContent(); - $this->elementEnd('body'); - $this->endHTML(); - } -} diff --git a/lib/router.php b/lib/router.php index d04a37d697..32012bc729 100644 --- a/lib/router.php +++ b/lib/router.php @@ -252,9 +252,6 @@ class Router $m->connect('conversation/:id', array('action' => 'conversation'), array('id' => '[0-9]+')); - $m->connect('conversation/:id/replies', - array('action' => 'conversationreplies'), - array('id' => '[0-9]+')); $m->connect('message/new', array('action' => 'newmessage')); $m->connect('message/new?to=:to', array('action' => 'newmessage'), array('to' => Nickname::DISPLAY_FMT)); diff --git a/lib/threadednoticelist.php b/lib/threadednoticelist.php index 6d8570fbee..e8abeb74fc 100644 --- a/lib/threadednoticelist.php +++ b/lib/threadednoticelist.php @@ -361,7 +361,7 @@ class ThreadedNoticeListMoreItem extends NoticeListItem function showMiniForm() { $id = $this->notice->conversation; - $url = common_local_url('conversationreplies', array('id' => $id)); + $url = common_local_url('conversation', array('id' => $id)); $n = Conversation::noticeCount($id) - 1;