Merge pull request #425 from Cadair/patch-1

Fix reply fallback prefix
This commit is contained in:
Benoit Marty 2019-08-06 11:23:37 +02:00 committed by GitHub
commit c450849cc3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -306,12 +306,12 @@ internal class LocalEchoEventFactory @Inject constructor(private val credentials
private fun buildReplyFallback(body: TextContent, originalSenderId: String?, newBodyText: String): String {
val lines = body.text.split("\n")
val replyFallback = StringBuffer("><$originalSenderId>")
val replyFallback = StringBuffer("> <$originalSenderId>")
lines.forEachIndexed { index, s ->
if (index == 0) {
replyFallback.append(" $s")
} else {
replyFallback.append("\n>$s")
replyFallback.append("\n> $s")
}
}
replyFallback.append("\n\n").append(newBodyText)