aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/bin/indexer.php
diff options
context:
space:
mode:
authorAndreas Gohr <andi@splitbrain.org>2023-08-30 17:09:14 +0200
committerAndreas Gohr <andi@splitbrain.org>2023-08-30 17:09:14 +0200
commitd868eb89f182718a31113373a6272670bd7f8012 (patch)
tree7007e6fba6cf6f16616863e387f974772c03071d /bin/indexer.php
parent8c7c53b0321a3cd3116b8d3b2ad27863a38dece7 (diff)
downloaddokuwiki-d868eb89f182718a31113373a6272670bd7f8012.tar.gz
dokuwiki-d868eb89f182718a31113373a6272670bd7f8012.zip
codestyle adjustments: function declaration braces/spaces
Diffstat (limited to 'bin/indexer.php')
-rwxr-xr-xbin/indexer.php18
1 files changed, 12 insertions, 6 deletions
diff --git a/bin/indexer.php b/bin/indexer.php
index f533c723b..9b2d4261f 100755
--- a/bin/indexer.php
+++ b/bin/indexer.php
@@ -23,7 +23,8 @@ class IndexerCLI extends CLI
* @param Options $options
* @return void
*/
- protected function setup(Options $options) {
+ protected function setup(Options $options)
+ {
$options->setHelp(
'Updates the searchindex by indexing all new or changed pages. When the -c option is ' .
'given the index is cleared first.'
@@ -49,7 +50,8 @@ class IndexerCLI extends CLI
* @param Options $options
* @return void
*/
- protected function main(Options $options) {
+ protected function main(Options $options)
+ {
$this->clear = $options->getOpt('clear');
$this->quiet = $options->getOpt('quiet');
@@ -61,7 +63,8 @@ class IndexerCLI extends CLI
/**
* Update the index
*/
- protected function update() {
+ protected function update()
+ {
global $conf;
$data = [];
$this->quietecho("Searching pages... ");
@@ -78,7 +81,8 @@ class IndexerCLI extends CLI
*
* @param string $id
*/
- protected function index($id) {
+ protected function index($id)
+ {
$this->quietecho("$id... ");
idx_addPage($id, !$this->quiet, $this->clear);
$this->quietecho("done.\n");
@@ -87,7 +91,8 @@ class IndexerCLI extends CLI
/**
* Clear all index files
*/
- protected function clearindex() {
+ protected function clearindex()
+ {
$this->quietecho("Clearing index... ");
idx_get_indexer()->clear();
$this->quietecho("done.\n");
@@ -98,7 +103,8 @@ class IndexerCLI extends CLI
*
* @param string $msg
*/
- protected function quietecho($msg) {
+ protected function quietecho($msg)
+ {
if(!$this->quiet) echo $msg;
}
}