diff --git a/code/DocumentationService.php b/code/DocumentationService.php index cebe388..ccfba2e 100755 --- a/code/DocumentationService.php +++ b/code/DocumentationService.php @@ -277,7 +277,7 @@ class DocumentationService { $docs = Director::baseFolder() . '/' . Controller::join_links($entity, 'docs'); if(is_dir($docs)) { - self::register($entity, $docs, '', $entity, true); + self::register($entity, $docs, 'current', $entity, true); } } } diff --git a/code/controllers/DocumentationViewer.php b/code/controllers/DocumentationViewer.php index ac580d8..d3f60ff 100755 --- a/code/controllers/DocumentationViewer.php +++ b/code/controllers/DocumentationViewer.php @@ -345,8 +345,7 @@ class DocumentationViewer extends Controller { foreach($versions as $key => $version) { $linkingMode = ($currentVersion == $version) ? 'current' : 'link'; - - if(!$version) $version = 'Current'; + $output->push(new ArrayData(array( 'Title' => $version, 'Link' => $this->Link(implode('/',$this->Remaining), $entity->getFolder(), $version),