mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-20 00:24:43 +02:00
MESSENGER-4646 fix Server URL bugs and avoid using synapse URL before server selection
This commit is contained in:
@@ -32,7 +32,11 @@ import Foundation
|
||||
|
||||
var selectedIndex: Int {
|
||||
get {
|
||||
return UserDefaults.standard.integer(forKey: "Bwi_Server_Url_Helper_Index")
|
||||
if UserDefaults.standard.object(forKey: "Bwi_Server_Url_Helper_Index") != nil {
|
||||
return UserDefaults.standard.integer(forKey: "Bwi_Server_Url_Helper_Index")
|
||||
} else {
|
||||
return -1
|
||||
}
|
||||
}
|
||||
set(newSelectedIndex) {
|
||||
UserDefaults.standard.set(newSelectedIndex, forKey: "Bwi_Server_Url_Helper_Index")
|
||||
|
||||
Reference in New Issue
Block a user