-
Notifications
You must be signed in to change notification settings - Fork 951
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Financial Connections: added extra networking support.
- Loading branch information
1 parent
2481a64
commit b9256c1
Showing
7 changed files
with
80 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -63,6 +63,12 @@ final class PlaygroundMainViewModel: ObservableObject { | |
} | ||
} | ||
|
||
@Published var enableDataMode: Bool = PlaygroundUserDefaults.enableDataMode { | ||
didSet { | ||
PlaygroundUserDefaults.enableDataMode = enableDataMode | ||
} | ||
} | ||
|
||
@Published var email: String = PlaygroundUserDefaults.email { | ||
didSet { | ||
PlaygroundUserDefaults.email = email | ||
|
@@ -162,7 +168,8 @@ final class PlaygroundMainViewModel: ObservableObject { | |
enableBalancesPermission: enableBalancesPermission, | ||
customScenario: customScenario.rawValue, | ||
customPublicKey: customPublicKey, | ||
customSecretKey: customSecretKey | ||
customSecretKey: customSecretKey, | ||
enableDataMode: enableDataMode | ||
) { [weak self] setupPlaygroundResponse in | ||
if let setupPlaygroundResponse = setupPlaygroundResponse { | ||
PresentFinancialConnectionsSheet( | ||
|
@@ -231,6 +238,7 @@ private func SetupPlayground( | |
customScenario: String, | ||
customPublicKey: String, | ||
customSecretKey: String, | ||
enableDataMode: Bool, | ||
completionHandler: @escaping ([String: String]?) -> Void | ||
) { | ||
if !enableTestMode && email == "[email protected]" { | ||
|
@@ -253,6 +261,7 @@ private func SetupPlayground( | |
requestBody["custom_scenario"] = customScenario | ||
requestBody["custom_public_key"] = customPublicKey | ||
requestBody["custom_secret_key"] = customSecretKey | ||
requestBody["enable_data_mode"] = enableDataMode | ||
return try! JSONSerialization.data( | ||
withJSONObject: requestBody, | ||
options: .prettyPrinted | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters