We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f84194e commit b47683dCopy full SHA for b47683d
src/commonMain/kotlin/io/github/optimumcode/json/schema/OutputCollector.kt
@@ -185,7 +185,10 @@ public sealed class OutputCollector<T> private constructor(
185
hasErrors = true
186
}
187
188
- override fun childCollector(): Flag = Flag(this)
+ override fun childCollector(): Flag =
189
+ // once `valid` flag is set to false we can avoid creating child collectors
190
+ // because the validation result won't be changed
191
+ if (valid) Flag(this) else this
192
193
194
private class Basic(
0 commit comments