Bläddra i källkod

Merge pull request #473 from loopandlearn/remote-settings-teamid-check-exclude-loopapns

RemoteSettings: exclude Loop APNS from Team ID mismatch check
Marion Barker 9 månader sedan
förälder
incheckning
d9e03a7964
1 ändrade filer med 2 tillägg och 3 borttagningar
  1. 2 3
      LoopFollow/Remote/Settings/RemoteSettingsViewModel.swift

+ 2 - 3
LoopFollow/Remote/Settings/RemoteSettingsViewModel.swift

@@ -62,8 +62,7 @@ class RemoteSettingsViewModel: ObservableObject {
 
 
         // Determine if a comparison is needed and perform it.
         // Determine if a comparison is needed and perform it.
         switch remoteType {
         switch remoteType {
-        case .loopAPNS, .trc:
-            // For both Loop and TRC, the target Team ID is in the same storage location.
+        case .trc:
             // If the target ID is empty, there's nothing to compare.
             // If the target ID is empty, there's nothing to compare.
             guard !targetTeamId.isEmpty else {
             guard !targetTeamId.isEmpty else {
                 return false
                 return false
@@ -71,7 +70,7 @@ class RemoteSettingsViewModel: ObservableObject {
             // Return true if the IDs are different.
             // Return true if the IDs are different.
             return loopFollowTeamID != targetTeamId
             return loopFollowTeamID != targetTeamId
 
 
-        case .none, .nightscout:
+        case .loopAPNS, .none, .nightscout:
             // For other remote types, this check is not applicable.
             // For other remote types, this check is not applicable.
             return false
             return false
         }
         }