Handle an empty path to mean no pwd

Fixes #3398
This commit is contained in:
David Leadbeater
2024-12-28 00:09:05 +11:00
parent a8e5eef11c
commit 9db02fd152

View File

@ -69,7 +69,7 @@ struct TerminalView<ViewModel: TerminalViewModel>: View {
// The pwd of the focused surface as a URL
private var pwdURL: URL? {
guard let surfacePwd else { return nil }
guard let surfacePwd, surfacePwd != "" else { return nil }
return URL(fileURLWithPath: surfacePwd)
}