Skip to content

Commit 3eda99a

Browse files
fix: copy SessionIdleTimeoutSeconds unconditionally in Go NewClient()
The option was only copied when > 0, which silently normalized negative inputs. Other SDKs preserve the caller's value and gate only at spawn time. Align Go to match. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
1 parent eb496ba commit 3eda99a

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

go/client.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -218,9 +218,7 @@ func NewClient(options *ClientOptions) *Client {
218218
if options.Telemetry != nil {
219219
opts.Telemetry = options.Telemetry
220220
}
221-
if options.SessionIdleTimeoutSeconds > 0 {
222-
opts.SessionIdleTimeoutSeconds = options.SessionIdleTimeoutSeconds
223-
}
221+
opts.SessionIdleTimeoutSeconds = options.SessionIdleTimeoutSeconds
224222
}
225223

226224
// Default Env to current environment if not set

0 commit comments

Comments
 (0)