refactor: remove session syncing metadata

This commit is contained in:
Peter Steinberger
2025-12-23 00:50:42 +01:00
parent c0c20ebf3e
commit ce04308c17
11 changed files with 1 additions and 175 deletions

View File

@@ -5,8 +5,7 @@ enum SessionActions {
static func patchSession(
key: String,
thinking: String?? = nil,
verbose: String?? = nil,
syncing: SessionSyncingValue?? = nil) async throws
verbose: String?? = nil) async throws
{
var params: [String: AnyHashable] = ["key": AnyHashable(key)]
@@ -16,20 +15,6 @@ enum SessionActions {
if let verbose {
params["verboseLevel"] = verbose.map(AnyHashable.init) ?? AnyHashable(NSNull())
}
if let syncing {
let payload: AnyHashable = {
switch syncing {
case .none:
AnyHashable(NSNull())
case let .some(value):
switch value {
case let .bool(v): AnyHashable(v)
case let .string(v): AnyHashable(v)
}
}
}()
params["syncing"] = payload
}
_ = try await ControlChannel.shared.request(method: "sessions.patch", params: params)
}