Fix min/maxByOrNull function samples

This commit is contained in:
Abduqodiri Qurbonzoda
2020-06-23 07:20:14 +03:00
parent 684ca5029f
commit a04f70fb36
8 changed files with 41 additions and 41 deletions
@@ -399,7 +399,7 @@ object Aggregates : TemplateGroupBase() {
since("1.4")
doc { "Returns the first ${f.element} yielding the ${if (op == "maxBy") "largest" else "smallest"} value of the given function or `null` if there are no ${f.element.pluralize()}." }
sample("samples.collections.Collections.Aggregates.$op")
sample("samples.collections.Collections.Aggregates.$op$orNull")
val (elem, value, cmp) = if (op == "minBy") Triple("minElem", "minValue", ">") else Triple("maxElem", "maxValue", "<")
body {