Ignores brb.io if in the relay list. It's crashing the app too much with a weird implementation of the WebSockets protocol

This commit is contained in:
Vitor Pamplona
2023-09-01 12:36:03 -04:00
parent 672841c0ed
commit 18933b4326

View File

@@ -85,6 +85,9 @@ class Relay(
private var connectingBlock = AtomicBoolean()
fun connectAndRun(onConnected: (Relay) -> Unit) {
// BRB is crashing OkHttp Deflater object :(
if (url.contains("brb.io")) return
// If there is a connection, don't wait.
if (connectingBlock.getAndSet(true)) {
return