Skip to content

Commit

Permalink
Scala tweak
Browse files Browse the repository at this point in the history
  • Loading branch information
lenguyenthanh committed Nov 22, 2024
1 parent a68f539 commit 3f23a77
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion core/src/main/scala/format/pgn/Parser.scala
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ object Parser:
val escaped: P[String] = P.char('\\') *> (R.dquote | P.char('\\')).string
val valueChar: P[String] = escaped | P.charWhere(_ != '"').string
val tagValue: P[String] = valueChar.rep0.map(_.mkString).with1.surroundedBy(R.dquote)
val tagContent: P[Tag] = ((tagName <* R.wsp.rep) ~ tagValue).map(p => Tag(p._1, p._2))
val tagContent: P[Tag] = ((tagName <* R.wsp.rep) ~ tagValue).map(Tag(_, _))
val tag: P[Tag] = tagContent.between(P.char('['), P.char(']')) <* whitespace.rep0
val tags: P0[List[Tag]] = tag.rep0

Expand Down
2 changes: 1 addition & 1 deletion rating/src/main/scala/glicko/impl/RatingCalculator.scala
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ final private[glicko] class RatingCalculator(
}

// now iterate through the participants and confirm their new ratings
players.foreach { _.finaliseRating() }
players.foreach(_.finaliseRating())

/** This is the formula defined in step 6. It is also used for players who have not competed during the
* rating period.
Expand Down

0 comments on commit 3f23a77

Please sign in to comment.