1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-05 08:17:47 +02:00

[ticket/12683] Add progress bar to create_index

PHPBB3-12683
This commit is contained in:
rubencm
2021-03-24 18:50:29 +01:00
committed by Ruben Calvo
parent ce54ee5e6f
commit 0a24704b4f
15 changed files with 151 additions and 111 deletions

View File

@@ -1397,16 +1397,9 @@ function mcp_fork_topic($topic_ids)
$search_backend_factory = $phpbb_container->get('search.backend_factory');
$search = $search_backend_factory->get_active();
}
catch (RuntimeException $e)
catch (\phpbb\search\exception\no_search_backend_found_exception $e)
{
if (strpos($e->getMessage(), 'No service found') === 0)
{
trigger_error('NO_SUCH_SEARCH_MODULE');
}
else
{
throw $e;
}
trigger_error('NO_SUCH_SEARCH_MODULE');
}
$search_mode = 'post';
}

View File

@@ -637,16 +637,9 @@ function change_poster(&$post_info, $userdata)
$search_backend_factory = $phpbb_container->get('search.backend_factory');
$search = $search_backend_factory->get_active();
}
catch (RuntimeException $e)
catch (\phpbb\search\exception\no_search_backend_found_exception $e)
{
if (strpos($e->getMessage(), 'No service found') === 0)
{
trigger_error('NO_SUCH_SEARCH_MODULE');
}
else
{
throw $e;
}
trigger_error('NO_SUCH_SEARCH_MODULE');
}
$search->index_remove([], [$post_info['user_id'], $userdata['user_id']], []);

View File

@@ -680,16 +680,9 @@ function split_topic($action, $topic_id, $to_forum_id, $subject)
$search_backend_factory = $phpbb_container->get('search.backend_factory');
$search = $search_backend_factory->get_active();
}
catch (RuntimeException $e)
catch (\phpbb\search\exception\no_search_backend_found_exception $e)
{
if (strpos($e->getMessage(), 'No service found') === 0)
{
trigger_error('NO_SUCH_SEARCH_MODULE');
}
else
{
throw $e;
}
trigger_error('NO_SUCH_SEARCH_MODULE');
}
$search->index('edit', (int) $first_post_data['post_id'], $first_post_data['post_text'], $subject, (int) $first_post_data['poster_id'], (int) $first_post_data['forum_id']);