Skip to content

Commit

Permalink
Update detekt-rules-style/src/main/kotlin/io/gitlab/arturbosch/detekt…
Browse files Browse the repository at this point in the history
…/rules/style/MultilineRawStringIndentation.kt

Co-authored-by: marschwar <marschwar@users.noreply.github.com>
  • Loading branch information
BraisGabin and marschwar committed Jul 23, 2022
1 parent 5146cea commit 487cee5
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -156,7 +156,7 @@ private fun message(desiredIntent: Int, currentIndent: Int): String {
return "The indentation should be $desiredIntent but it is $currentIndent."
}

private val rawStringRegex = "\"\"\"\n(.|\n)*\n *\"\"\"".toRegex()
private val rawStringRegex = "\"{3}\n.*\n *\"{3}".toRegex(RegexOption.DOT_MATCHES_ALL)

private fun String.countIndent() = this.takeWhile { it == ' ' }.count()

Expand Down

0 comments on commit 487cee5

Please sign in to comment.