Skip to content

Commit

Permalink
Merge pull request #16264 from yahya-lafhal/fix_study_chapter_orienta…
Browse files Browse the repository at this point in the history
…tion

Use toLowerCase on the orientation color to handle it correctly when adding a chapter
  • Loading branch information
ornicar authored Oct 24, 2024
2 parents 9b6e13f + d97bc53 commit ea16f5e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/study/src/main/ChapterMaker.scala
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ private[study] object ChapterMaker:
case Fixed(color: Color) extends Orientation(color.name, color.some)
case Auto extends Orientation("automatic", none)
object Orientation:
def apply(str: String) = Color.fromName(str).fold[Orientation](Auto)(Fixed.apply)
def apply(str: String) = Color.fromName(str.toLowerCase()).fold[Orientation](Auto)(Fixed.apply)

case class Data(
name: StudyChapterName,
Expand Down

0 comments on commit ea16f5e

Please sign in to comment.