only show 3 games in auto reports
This commit is contained in:
parent
92fc7ff244
commit
c49381ef96
|
@ -25,8 +25,8 @@ case class Evaluation(
|
|||
case Evaluation.Mark ⇒ "definitely cheating"
|
||||
}
|
||||
|
||||
def reportText = {
|
||||
val gameText = games map { g ⇒ s"${g.url} $g" } mkString "\n"
|
||||
def reportText(maxGames: Int = 10) = {
|
||||
val gameText = games take maxGames map { g ⇒ s"${g.url} $g" } mkString "\n"
|
||||
s"[AUTOREPORT] Cheat evaluation: $percent%\n$gameText"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -45,7 +45,7 @@ final class Evaluator(
|
|||
val g = perfs.global.glicko
|
||||
((g.deviation <= autoDeviationThreshold && g.rating >= autoRatingThreshold) ?? generate(user.id, false)) foreach {
|
||||
case Some(eval) if (eval.action == Evaluation.Report) ⇒
|
||||
reporter ! lila.hub.actorApi.report.Cheater(user.id, eval.reportText)
|
||||
reporter ! lila.hub.actorApi.report.Cheater(user.id, eval reportText 3)
|
||||
case _ ⇒
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue