mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-04-18 04:38:27 +00:00
Add "https://" to the config URI if it doesn't exist
This commit is contained in:
parent
9d78fc2e29
commit
1bb372741e
3 changed files with 8 additions and 4 deletions
|
|
@ -2,6 +2,6 @@ import Foundation
|
|||
|
||||
public enum AppGitInfo {
|
||||
public static let branch = "master"
|
||||
public static let commit = "d0418ae07"
|
||||
public static let commit = "9d78fc2e2"
|
||||
public static let tag = "6.1.0-alpha"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -219,10 +219,10 @@ struct ToastView: View {
|
|||
.default_text_style(styleSize: 15)
|
||||
.padding(8)
|
||||
|
||||
case "uri_handler_config_success":
|
||||
case "Success_uri_handler_config_success":
|
||||
Text("uri_handler_config_success_toast")
|
||||
.multilineTextAlignment(.center)
|
||||
.foregroundStyle(Color.redDanger500)
|
||||
.foregroundStyle(Color.greenSuccess500)
|
||||
.default_text_style(styleSize: 15)
|
||||
.padding(8)
|
||||
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ class URIHandler {
|
|||
CoreContext.shared.removeCoreDelegateStub(delegate: uriHandlerCoreDelegate!)
|
||||
}
|
||||
if state == .Successful {
|
||||
toast("uri_handler_config_success")
|
||||
toast("Success_uri_handler_config_success")
|
||||
CoreContext.shared.removeCoreDelegateStub(delegate: uriHandlerCoreDelegate!)
|
||||
}
|
||||
})
|
||||
|
|
@ -106,6 +106,10 @@ class URIHandler {
|
|||
urlString = String(urlString.dropFirst(2))
|
||||
}
|
||||
|
||||
if !urlString.starts(with: "https://") {
|
||||
urlString = "https://" + urlString
|
||||
}
|
||||
|
||||
core.config?.setString(section: "misc", key: "config-uri", value: urlString)
|
||||
try core.setProvisioninguri(newValue: urlString)
|
||||
core.stop()
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue