Remove push proxy scheme build setting

This commit is contained in:
Shadowfacts 2024-04-11 13:00:39 -04:00
parent 1cd6af1236
commit bc516a6326
3 changed files with 2 additions and 5 deletions

View File

@ -24,15 +24,13 @@ public struct PushManager {
@MainActor @MainActor
private static func createPushManager() -> any _PushManager { private static func createPushManager() -> any _PushManager {
guard let info = Bundle.main.object(forInfoDictionaryKey: "TuskerInfo") as? [String: Any], guard let info = Bundle.main.object(forInfoDictionaryKey: "TuskerInfo") as? [String: Any],
let scheme = info["PushProxyScheme"] as? String,
let host = info["PushProxyHost"] as? String, let host = info["PushProxyHost"] as? String,
!scheme.isEmpty,
!host.isEmpty else { !host.isEmpty else {
logger.debug("Missing proxy info, push disabled") logger.debug("Missing proxy info, push disabled")
return DisabledPushManager() return DisabledPushManager()
} }
var endpoint = URLComponents() var endpoint = URLComponents()
endpoint.scheme = scheme endpoint.scheme = "https"
endpoint.host = host endpoint.host = host
let url = endpoint.url! let url = endpoint.url!
logger.debug("Push notifications enabled with proxy \(url.absoluteString, privacy: .public)") logger.debug("Push notifications enabled with proxy \(url.absoluteString, privacy: .public)")

View File

@ -3,3 +3,4 @@
DEVELOPMENT_TEAM = YOUR_TEAM_ID DEVELOPMENT_TEAM = YOUR_TEAM_ID
BUNDLE_ID_PREFIX = com.example BUNDLE_ID_PREFIX = com.example
TUSKER_PUSH_PROXY_HOST =

View File

@ -105,8 +105,6 @@
<dict> <dict>
<key>PushProxyHost</key> <key>PushProxyHost</key>
<string>$(TUSKER_PUSH_PROXY_HOST)</string> <string>$(TUSKER_PUSH_PROXY_HOST)</string>
<key>PushProxyScheme</key>
<string>$(TUSKER_PUSH_PROXY_SCHEME)</string>
<key>SentryDSN</key> <key>SentryDSN</key>
<string>$(SENTRY_DSN)</string> <string>$(SENTRY_DSN)</string>
</dict> </dict>