Improved testability of BlogListGenerator
This commit is contained in:
parent
89e756819d
commit
9ac51e0523
2 changed files with 3 additions and 3 deletions
|
@ -195,7 +195,7 @@ if ($config["design"]["drawer"] == "on") {
|
|||
if ($getblog == "") { // Run when on main blog
|
||||
if ($navblog != "main.md") { // excluding main blog
|
||||
// creating navigation item
|
||||
BlogListGenerator::listBlog(
|
||||
echo BlogListGenerator::listBlog(
|
||||
"./blogs/",
|
||||
$navblog,
|
||||
$config["blog"]["title"]
|
||||
|
@ -206,7 +206,7 @@ if ($config["design"]["drawer"] == "on") {
|
|||
// -> this blog will be excluded
|
||||
if ($getblog . ".md" != $navblog) {
|
||||
// creating navigation item
|
||||
BlogListGenerator::listBlog(
|
||||
echo BlogListGenerator::listBlog(
|
||||
"./blogs/",
|
||||
$navblog,
|
||||
$blogmaintitle
|
||||
|
|
|
@ -64,7 +64,7 @@ class BlogListGenerator
|
|||
$itemurl = substr($blog, 6, strpos($blog, "\n") - 6);
|
||||
$atag = "<a class='nav-item' href='$itemurl'>$itemname</a>";
|
||||
}
|
||||
echo $atag;
|
||||
return $atag;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Reference in a new issue