Skip to content

Commit 218dd12

Browse files
committed
fixup! address Danielle's comments
1 parent 3d18f71 commit 218dd12

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

lib/httpapi/server.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -255,17 +255,15 @@ func NewServer(ctx context.Context, config ServerConfig) (*Server, error) {
255255
initialPrompt = FormatMessage(config.AgentType, config.InitialPrompt)
256256
}
257257

258-
// Create appropriate conversation based on transport type
259258
var conversation st.Conversation
260-
if config.Transport == "acp" {
259+
if config.Transport == TransportACP {
261260
// For ACP, cast AgentIO to *acpio.ACPAgentIO
262261
acpIO, ok := config.AgentIO.(*acpio.ACPAgentIO)
263262
if !ok {
264263
return nil, fmt.Errorf("ACP transport requires ACPAgentIO")
265264
}
266265
conversation = acpio.NewACPConversation(ctx, acpIO, logger, initialPrompt, emitter, config.Clock)
267266
} else {
268-
// Default to PTY transport
269267
proc, ok := config.AgentIO.(*termexec.Process)
270268
if !ok && config.AgentIO != nil {
271269
return nil, fmt.Errorf("PTY transport requires termexec.Process")

0 commit comments

Comments
 (0)