mirror of
https://github.com/friendica/friendica
synced 2025-05-08 21:44:10 +02:00
Decouple conversation creation from rendering
- This allows to separately obtain a list of threads for rendering without having to deal with an already-formed HTML output
This commit is contained in:
parent
31fbe70ec7
commit
706444bdb2
14 changed files with 294 additions and 269 deletions
|
@ -99,7 +99,7 @@ class Filed extends BaseSearch
|
|||
|
||||
$items = Post::toArray(Post::selectForUser(DI::userSession()->getLocalUserId(), Item::DISPLAY_FIELDLIST, $item_condition, $item_params));
|
||||
|
||||
$o .= DI::conversation()->create($items, Conversation::MODE_FILED, false, false, '', DI::userSession()->getLocalUserId());
|
||||
$o .= DI::conversation()->render($items, Conversation::MODE_FILED, false, false, '', DI::userSession()->getLocalUserId());
|
||||
|
||||
if (DI::pConfig()->get(DI::userSession()->getLocalUserId(), 'system', 'infinite_scroll')) {
|
||||
$o .= HTML::scrollLoader();
|
||||
|
|
|
@ -213,7 +213,7 @@ class Index extends BaseSearch
|
|||
|
||||
Logger::info('Start Conversation.', ['q' => $search]);
|
||||
|
||||
$o .= DI::conversation()->create($items, Conversation::MODE_SEARCH, false, false, 'commented', DI::userSession()->getLocalUserId());
|
||||
$o .= DI::conversation()->render($items, Conversation::MODE_SEARCH, false, false, 'commented', DI::userSession()->getLocalUserId());
|
||||
|
||||
if (DI::pConfig()->get(DI::userSession()->getLocalUserId(), 'system', 'infinite_scroll')) {
|
||||
$o .= HTML::scrollLoader();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue