From 8d7d704bc32fd26dc641ff4c612127748c4f391e Mon Sep 17 00:00:00 2001 From: Joe Szymanski Date: Sun, 3 Dec 2017 22:54:22 -0500 Subject: [PATCH] Make sure the live query server URL properly handle wss schemes (#135) --- Sources/ParseLiveQuery/Client.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sources/ParseLiveQuery/Client.swift b/Sources/ParseLiveQuery/Client.swift index a5d98538..c46c4eb1 100644 --- a/Sources/ParseLiveQuery/Client.swift +++ b/Sources/ParseLiveQuery/Client.swift @@ -52,7 +52,7 @@ open class Client: NSObject { fatalError("Server should be a valid URL.") } var components = cmpts - components.scheme = components.scheme == "https" ? "wss" : "ws" + components.scheme = (components.scheme == "https" || components.scheme == "wss") ? "wss" : "ws" // Simple incrementing generator - can't use ++, that operator is deprecated! var currentRequestId = 0