Skip to content

Commit 797a537

Browse files
authored
Merge pull request #227 from novalagung/refactor/structure
fix: header
2 parents 57c98d7 + 3868c50 commit 797a537

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

etc/fix-webbook.go

+3-1
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ func postAdjustment() {
8787
}(htmlString)
8888

8989
newTitle := oldTitle
90-
isLandingPage := (oldTitle == "Introduction · HonKit") || (oldTitle == "Introduction · HonKit")
90+
isLandingPage := (oldTitle == "Introduction · GitBook") || (oldTitle == "Introduction · HonKit") || (oldTitle == "Introduction · GitBook") || (oldTitle == "Introduction · HonKit")
9191
if isLandingPage {
9292
newTitle = bookName
9393
} else {
@@ -104,7 +104,9 @@ func postAdjustment() {
104104
if newTitle == "Belajar Golang" {
105105
newTitle = "Tutorial Gratis Belajar Dasar Pemrograman Golang Mulai Dari 0"
106106
}
107+
newTitle = strings.ReplaceAll(newTitle, "· GitBook", fmt.Sprintf("- %s", bookName))
107108
newTitle = strings.ReplaceAll(newTitle, "· HonKit", fmt.Sprintf("- %s", bookName))
109+
newTitle = strings.ReplaceAll(newTitle, "· GitBook", fmt.Sprintf("- %s", bookName))
108110
newTitle = strings.ReplaceAll(newTitle, "· HonKit", fmt.Sprintf("- %s", bookName))
109111

110112
// ==== remove the "A.2"-ish from the title

0 commit comments

Comments
 (0)