From 338253e4e22f2c734cb31f9de34f689d022bd9ab Mon Sep 17 00:00:00 2001 From: Adrien Piquerez Date: Mon, 27 May 2024 15:32:55 +0200 Subject: [PATCH] Fix #1405 - default artifact --- .../src/main/scala/scaladex/view/model/ProjectHeader.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/template/src/main/scala/scaladex/view/model/ProjectHeader.scala b/modules/template/src/main/scala/scaladex/view/model/ProjectHeader.scala index f3b848a14..7f9affbab 100644 --- a/modules/template/src/main/scala/scaladex/view/model/ProjectHeader.scala +++ b/modules/template/src/main/scala/scaladex/view/model/ProjectHeader.scala @@ -55,7 +55,7 @@ final case class ProjectHeader( def getDefaultArtifact(language: Option[Language], platform: Option[Platform]): Artifact = { val artifacts = latestArtifacts .filter(artifact => language.forall(_ == artifact.language) && platform.forall(_ == artifact.platform)) - val stableArtifacts = latestArtifacts.filter(_.version.isStable) + val stableArtifacts = artifacts.filter(_.version.isStable) def byName(artifacts: Seq[Artifact]): Option[Artifact] = defaultArtifactName.toSeq