Remove dot from end of links in chat

This commit is contained in:
nea
2023-09-01 00:50:12 +02:00
parent 41dc53e00e
commit c912ee90d3

View File

@@ -53,7 +53,7 @@ object ChatLinks : FirmamentFeature {
private fun isUrlAllowed(url: String) = isHostAllowed(url.removePrefix("https://").substringBefore("/"))
override val config get() = TConfig
val urlRegex = "https://[^. ]+\\.[^ ]+( |$)".toRegex()
val urlRegex = "https://[^. ]+\\.[^ ]+(\\.? |$)".toRegex()
data class Image(
val texture: Identifier,