Skip to content

Commit

Permalink
Update for namespaces
Browse files Browse the repository at this point in the history
  • Loading branch information
gamma committed Feb 1, 2021
1 parent 72ec21f commit 39abe1c
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions action/aggregate.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,9 @@ public function register(Doku_Event_Handler $controller) {
$controller->register_hook('TOOLBAR_DEFINE', 'AFTER', $this, 'siteexport_aggregate_button', array ());
}

private function prefixStart($entry) {
return noNS($namespace) == $conf['start'] ? $namespace : $namespace . ':' . $conf['start'];
private function prefixStart($namespace) {
global $conf;
return getNS($namespace) . ':' . $conf['start'];
}

public function siteexport_aggregate(Doku_Event &$event)
Expand Down Expand Up @@ -62,10 +63,10 @@ public function siteexport_aggregate(Doku_Event &$event)
$values = $functions->__getOrderedListOfPagesForStartEnd($lookupNS, $INPUT->int( 'mergecompare_start' ), $INPUT->int( 'mergecompare_end', PHP_INT_MAX ) );
} else {
$values = $functions->__getOrderedListOfPagesForID($lookupNS, $exportBase);
$values = array(end( $values )); // the list above has the $exportBase element at the very end
}
}


$includeSelected = $INPUT->str('includeSelectedVersion', 'true', true ) === 'true';
if( !$includeSelected && count( $values ) > 1 ) {
array_pop( $values ); // Remove last entry which is the selected version, but only if more than one entry exists
Expand Down

0 comments on commit 39abe1c

Please sign in to comment.