Fixed some incorrect logic (previously prevented joining other rooms in a server)
This commit is contained in:
parent
d3b54b84d0
commit
83fa679574
|
@ -56,8 +56,10 @@ public final class OpenGroupManagerV2 : NSObject {
|
|||
serverOptions = serverOptions.union(legacyServerOptions)
|
||||
}
|
||||
|
||||
// First check if there is an existing poller for the given server options
|
||||
guard serverOptions.first(where: { OpenGroupManagerV2.shared.pollers[$0] != nil }) == nil else { return true }
|
||||
// First check if there is no poller for the specified server
|
||||
if serverOptions.first(where: { OpenGroupManagerV2.shared.pollers[$0] != nil }) == nil {
|
||||
return false
|
||||
}
|
||||
|
||||
// Then check if there is an existing open group thread
|
||||
let hasExistingThread: Bool = serverOptions.contains(where: { serverName in
|
||||
|
|
Loading…
Reference in New Issue