remove deprecated app parameter from conversation()

This commit is contained in:
zotlabs 2017-06-20 15:53:01 -07:00
parent 07a8151ae6
commit 31e0812711
8 changed files with 10 additions and 11 deletions

View File

@ -365,10 +365,10 @@ class Channel extends \Zotlabs\Web\Controller {
if($checkjs->disabled()) { if($checkjs->disabled()) {
$o .= conversation($a,$items,'channel',$update,'traditional'); $o .= conversation($items,'channel',$update,'traditional');
} }
else { else {
$o .= conversation($a,$items,'channel',$update,$page_mode); $o .= conversation($items,'channel',$update,$page_mode);
} }
if((! $update) || ($checkjs->disabled())) { if((! $update) || ($checkjs->disabled())) {

View File

@ -308,12 +308,12 @@ class Display extends \Zotlabs\Web\Controller {
if ($checkjs->disabled()) { if ($checkjs->disabled()) {
$o .= conversation($a, $items, 'display', $update, 'traditional'); $o .= conversation($items, 'display', $update, 'traditional');
if ($items[0]['title']) if ($items[0]['title'])
\App::$page['title'] = $items[0]['title'] . " - " . \App::$page['title']; \App::$page['title'] = $items[0]['title'] . " - " . \App::$page['title'];
} }
else { else {
$o .= conversation($a, $items, 'display', $update, 'client'); $o .= conversation($items, 'display', $update, 'client');
} }
if($updateable) { if($updateable) {

View File

@ -818,7 +818,7 @@ class Item extends \Zotlabs\Web\Controller {
$datarray['owner'] = $owner_xchan; $datarray['owner'] = $owner_xchan;
$datarray['author'] = $observer; $datarray['author'] = $observer;
$datarray['attach'] = json_encode($datarray['attach']); $datarray['attach'] = json_encode($datarray['attach']);
$o = conversation($a,array($datarray),'search',false,'preview'); $o = conversation(array($datarray),'search',false,'preview');
// logger('preview: ' . $o, LOGGER_DEBUG); // logger('preview: ' . $o, LOGGER_DEBUG);
echo json_encode(array('preview' => $o)); echo json_encode(array('preview' => $o));
killme(); killme();

View File

@ -68,7 +68,7 @@ class Moderate extends \Zotlabs\Web\Controller {
$items = array(); $items = array();
} }
$o = conversation($a,$items,'moderate',false,'traditional'); $o = conversation($items,'moderate',false,'traditional');
return $o; return $o;

View File

@ -551,7 +551,7 @@ class Network extends \Zotlabs\Web\Controller {
$mode = (($nouveau) ? 'network-new' : 'network'); $mode = (($nouveau) ? 'network-new' : 'network');
$o .= conversation($a,$items,$mode,$update,$page_mode); $o .= conversation($items,$mode,$update,$page_mode);
if(($items) && (! $update)) if(($items) && (! $update))
$o .= alt_pager($a,count($items)); $o .= alt_pager($a,count($items));

View File

@ -167,7 +167,7 @@ class Pubstream extends \Zotlabs\Web\Controller {
// fake it // fake it
$mode = ('network'); $mode = ('network');
$o .= conversation($a,$items,$mode,$update,$page_mode); $o .= conversation($items,$mode,$update,$page_mode);
if(($items) && (! $update)) if(($items) && (! $update))
$o .= alt_pager($a,count($items)); $o .= alt_pager($a,count($items));

View File

@ -225,7 +225,7 @@ class Search extends \Zotlabs\Web\Controller {
else else
$o .= '<h2>' . sprintf( t('Search results for: %s'),htmlspecialchars($search, ENT_COMPAT,'UTF-8')) . '</h2>'; $o .= '<h2>' . sprintf( t('Search results for: %s'),htmlspecialchars($search, ENT_COMPAT,'UTF-8')) . '</h2>';
$o .= conversation($a,$items,'search',$update,'client'); $o .= conversation($items,'search',$update,'client');
$o .= '</div>'; $o .= '</div>';

View File

@ -442,7 +442,6 @@ function is_edit_activity($item) {
* figures out how to determine page owner and other contextual items * figures out how to determine page owner and other contextual items
* that are based on unique features of the calling module. * that are based on unique features of the calling module.
* *
* @param App &$a
* @param array $items * @param array $items
* @param string $mode * @param string $mode
* @param boolean $update * @param boolean $update
@ -450,7 +449,7 @@ function is_edit_activity($item) {
* @param string $prepared_item * @param string $prepared_item
* @return string * @return string
*/ */
function conversation(&$a, $items, $mode, $update, $page_mode = 'traditional', $prepared_item = '') { function conversation($items, $mode, $update, $page_mode = 'traditional', $prepared_item = '') {
$content_html = ''; $content_html = '';
$o = ''; $o = '';