aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--core/src/main/kotlin/Kotlin/DocumentationBuilder.kt4
-rw-r--r--core/src/main/kotlin/Model/DocumentationNode.kt6
2 files changed, 7 insertions, 3 deletions
diff --git a/core/src/main/kotlin/Kotlin/DocumentationBuilder.kt b/core/src/main/kotlin/Kotlin/DocumentationBuilder.kt
index 3fb22589..205b44bd 100644
--- a/core/src/main/kotlin/Kotlin/DocumentationBuilder.kt
+++ b/core/src/main/kotlin/Kotlin/DocumentationBuilder.kt
@@ -290,7 +290,9 @@ class DocumentationBuilder
}
fun DocumentationNode.appendDefaultSinceKotlin() {
- sinceKotlin = passConfiguration.sinceKotlin
+ if (sinceKotlin == null) {
+ sinceKotlin = passConfiguration.sinceKotlin
+ }
}
fun DocumentationNode.appendModifiers(descriptor: DeclarationDescriptor) {
diff --git a/core/src/main/kotlin/Model/DocumentationNode.kt b/core/src/main/kotlin/Model/DocumentationNode.kt
index 84f9a453..617816b3 100644
--- a/core/src/main/kotlin/Model/DocumentationNode.kt
+++ b/core/src/main/kotlin/Model/DocumentationNode.kt
@@ -122,8 +122,10 @@ open class DocumentationNode(val name: String,
var sinceKotlin: String?
get() = references(RefKind.SinceKotlin).singleOrNull()?.to?.name
set(value) {
- if(value == null) return dropReferences { it.kind == RefKind.SinceKotlin }
- append(DocumentationNode(value, Content.Empty, NodeKind.Value), RefKind.SinceKotlin)
+ dropReferences { it.kind == RefKind.SinceKotlin }
+ if (value != null) {
+ append(DocumentationNode(value, Content.Empty, NodeKind.Value), RefKind.SinceKotlin)
+ }
}
val supertypes: List<DocumentationNode>