aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorkisenka <qtuzov@gmail.com>2014-10-13 18:52:57 +0400
committerkisenka <qtuzov@gmail.com>2014-10-13 18:52:57 +0400
commitb3d2b8c429ca840d7a1d09c83fa3e6426b0270cc (patch)
tree6ac1776f36dc2d25d586cd545f3869d0e01d3f35 /src
parentf5d6bc3129e2cd5ba9511415b3e700b22f28c2da (diff)
downloaddokka-b3d2b8c429ca840d7a1d09c83fa3e6426b0270cc.tar.gz
dokka-b3d2b8c429ca840d7a1d09c83fa3e6426b0270cc.tar.bz2
dokka-b3d2b8c429ca840d7a1d09c83fa3e6426b0270cc.zip
Replace internal index pages URLs from "/index.html" with "/"
Diffstat (limited to 'src')
-rw-r--r--src/Formats/KotlinWebsiteFormatService.kt8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/Formats/KotlinWebsiteFormatService.kt b/src/Formats/KotlinWebsiteFormatService.kt
index 9fee14ff..8170b5a9 100644
--- a/src/Formats/KotlinWebsiteFormatService.kt
+++ b/src/Formats/KotlinWebsiteFormatService.kt
@@ -18,9 +18,11 @@ public class KotlinWebsiteFormatService(locationService: LocationService,
}
override fun formatLink(text: String, location: Location): String {
- return "<a href=\"${location.path
- .replace("\\", "/")
- .replaceAfterLast(".","html")}\">${text}</a>"
+ val href = location.path.replace("\\", "/")
+ .replaceAfterLast(".", "html")
+ .replace("/index.html", "/");
+
+ return "<a href=\"${href}\">${text}</a>"
}
override fun formatLink(text: String, href: String): String {