@@ -13,10 +13,6 @@ public extension MutagenDaemon {
13
13
return
14
14
}
15
15
sessionState = sessions. sessionStates. map { FileSyncSession ( state: $0) }
16
- if sessionState. isEmpty {
17
- logger. info ( " No sync sessions found " )
18
- await stop ( )
19
- }
20
16
}
21
17
22
18
func createSession(
@@ -61,7 +57,8 @@ public extension MutagenDaemon {
61
57
}
62
58
63
59
func deleteSessions( ids: [ String ] ) async throws ( DaemonError) {
64
- // Terminating sessions does not require prompting
60
+ // Terminating sessions does not require prompting, according to the
61
+ // Mutagen CLI
65
62
let ( stream, promptID) = try await host ( allowPrompts: false )
66
63
defer { stream. cancel ( ) }
67
64
guard case . running = state else { return }
@@ -79,7 +76,9 @@ public extension MutagenDaemon {
79
76
}
80
77
81
78
func pauseSessions( ids: [ String ] ) async throws ( DaemonError) {
82
- let ( stream, promptID) = try await host ( )
79
+ // Pausing sessions does not require prompting, according to the
80
+ // Mutagen CLI
81
+ let ( stream, promptID) = try await host ( allowPrompts: false )
83
82
defer { stream. cancel ( ) }
84
83
guard case . running = state else { return }
85
84
do {
@@ -96,7 +95,9 @@ public extension MutagenDaemon {
96
95
}
97
96
98
97
func resumeSessions( ids: [ String ] ) async throws ( DaemonError) {
99
- let ( stream, promptID) = try await host ( )
98
+ // Resuming sessions does not require prompting, according to the
99
+ // Mutagen CLI
100
+ let ( stream, promptID) = try await host ( allowPrompts: false )
100
101
defer { stream. cancel ( ) }
101
102
guard case . running = state else { return }
102
103
do {
0 commit comments