Skip to content

Commit

Permalink
Update Logging, fix export issue with depth=0
Browse files Browse the repository at this point in the history
Previously iut allways fell back to the root index instead of the namespace index.
  • Loading branch information
gamma committed Jul 7, 2023
1 parent 3354083 commit 647a87a
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions action/ajax.php
Expand Up @@ -350,15 +350,15 @@ private function __get_siteexport_list($NS, $overrideCache = false) {

$PAGE = "";
$NS = $this->namespace = $this->functions->getNamespaceFromID($NS, $PAGE);
$this->functions->debug->message("ROOT Namespace to export from: '{$NS}' / {$this->namespace}", null, 1);
$this->functions->debug->message("ROOT Namespace to export from: '{$NS}' / {$this->namespace}", null, 2);

$depth = $this->getConf('depth');
$query = '';
$doSearch = 'search_allpages';

switch ($INPUT->int('depthType')) {
case 0:
$query = $this->functions->cleanID(str_replace(":", "/", $NS . ':' . $PAGE));
$PAGE = $this->functions->cleanID(str_replace(":", "/", $NS . ':' . $PAGE));
$NS = (new PageResolver($NS))->resolveId($PAGE);
$exists = page_exists($NS);

Expand All @@ -370,7 +370,8 @@ private function __get_siteexport_list($NS, $overrideCache = false) {
{
return array();
}


$this->functions->debug->message("Exporting the following sites: ", $data, 2);
return $data;
} else {
// Does not exist, try next case
Expand Down

0 comments on commit 647a87a

Please sign in to comment.