diff --git a/OwnTracks/OwnTracks/Settings.m b/OwnTracks/OwnTracks/Settings.m index 569fe865..be66f9d2 100644 --- a/OwnTracks/OwnTracks/Settings.m +++ b/OwnTracks/OwnTracks/Settings.m @@ -911,10 +911,6 @@ + (NSString *)theSubscriptions { + (NSString *)theUserId { int mode = [self intForKey:@"mode"]; switch (mode) { - case CONNECTION_MODE_HTTP: - return @"http"; - break; - case CONNECTION_MODE_PUBLIC: return @"user"; break; @@ -923,6 +919,7 @@ + (NSString *)theUserId { return [self stringForKey:@"user"]; break; + case CONNECTION_MODE_HTTP: case CONNECTION_MODE_PRIVATE: default: return [self stringForKey:@"user_preference"]; @@ -968,7 +965,6 @@ + (NSString *)theMqttUser { int mode = [self intForKey:@"mode"]; switch (mode) { case CONNECTION_MODE_PUBLIC: - case CONNECTION_MODE_HTTP: case CONNECTION_MODE_WATSON: return nil; break; @@ -983,6 +979,7 @@ + (NSString *)theMqttUser { [self theDeviceId]]; break; + case CONNECTION_MODE_HTTP: case CONNECTION_MODE_PRIVATE: default: return [self stringForKey:@"user_preference"]; @@ -994,7 +991,6 @@ + (NSString *)theMqttPass { int mode = [self intForKey:@"mode"]; switch (mode) { case CONNECTION_MODE_PUBLIC: - case CONNECTION_MODE_HTTP: case CONNECTION_MODE_WATSON: return nil; break; @@ -1007,6 +1003,7 @@ + (NSString *)theMqttPass { return [self stringForKey:@"token"]; break; + case CONNECTION_MODE_HTTP: case CONNECTION_MODE_PRIVATE: default: return [self stringForKey:@"pass_preference"]; @@ -1017,7 +1014,6 @@ + (NSString *)theMqttPass { + (BOOL)theMqttAuth { int mode = [self intForKey:@"mode"]; switch (mode) { - case CONNECTION_MODE_HTTP: case CONNECTION_MODE_PUBLIC: case CONNECTION_MODE_WATSON: return FALSE; @@ -1028,6 +1024,7 @@ + (BOOL)theMqttAuth { return TRUE; break; + case CONNECTION_MODE_HTTP: case CONNECTION_MODE_PRIVATE: default: return [self boolForKey:@"auth_preference"];