dependency injection in ShhShellApp via the init

added keymanager to sshhandler so it can access keys
This commit is contained in:
neon443
2025-07-02 08:19:01 +01:00
parent 935c118d35
commit ce162f437a
9 changed files with 29 additions and 15 deletions

View File

@@ -49,9 +49,10 @@ struct ContentView: View {
}
#Preview {
let keymanager = KeyManager()
ContentView(
handler: SSHHandler(host: Host.debug),
handler: SSHHandler(host: Host.debug, keyManager: keymanager),
hostsManager: HostsManager(),
keyManager: KeyManager()
keyManager: keymanager
)
}