Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit5fc578e

Browse files
committed
consistency
1 parent700a00c commit5fc578e

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

‎agent/agentcontainers/api.go

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1087,8 +1087,8 @@ func (api *API) maybeInjectSubAgentIntoContainerLocked(ctx context.Context, dc c
10871087
returnxerrors.Errorf("read devcontainer config: %w",err)
10881088
}
10891089

1090-
ignore:=config.Configuration.Customizations.Coder.Ignore
1091-
ifignore {
1090+
dcIgnored:=config.Configuration.Customizations.Coder.Ignore
1091+
ifdcIgnored {
10921092
proc.stop()
10931093
ifproc.agent.ID!=uuid.Nil {
10941094
// Unlock while doing the delete operation.
@@ -1104,7 +1104,7 @@ func (api *API) maybeInjectSubAgentIntoContainerLocked(ctx context.Context, dc c
11041104
proc.agent=SubAgent{}
11051105
proc.containerID=""
11061106
api.injectedSubAgentProcs[dc.WorkspaceFolder]=proc
1107-
api.ignoredDevcontainers[dc.WorkspaceFolder]=ignore
1107+
api.ignoredDevcontainers[dc.WorkspaceFolder]=dcIgnored
11081108
returnnil
11091109
}
11101110
}
@@ -1147,10 +1147,10 @@ func (api *API) maybeInjectSubAgentIntoContainerLocked(ctx context.Context, dc c
11471147
ranSubAgent:=false
11481148

11491149
// Clean up if injection fails.
1150-
varignored,setIgnoredbool
1150+
vardcIgnored,setDCIgnoredbool
11511151
deferfunc() {
1152-
ifsetIgnored {
1153-
api.ignoredDevcontainers[dc.WorkspaceFolder]=ignored
1152+
ifsetDCIgnored {
1153+
api.ignoredDevcontainers[dc.WorkspaceFolder]=dcIgnored
11541154
}
11551155
if!ranSubAgent {
11561156
proc.stop()
@@ -1230,8 +1230,8 @@ func (api *API) maybeInjectSubAgentIntoContainerLocked(ctx context.Context, dc c
12301230

12311231
// We only allow ignore to be set in the root customization layer to
12321232
// prevent weird interactions with devcontainer features.
1233-
ignored,setIgnored=config.Configuration.Customizations.Coder.Ignore,true
1234-
ifignored {
1233+
dcIgnored,setDCIgnored=config.Configuration.Customizations.Coder.Ignore,true
1234+
ifdcIgnored {
12351235
returnnil
12361236
}
12371237

@@ -1282,7 +1282,7 @@ func (api *API) maybeInjectSubAgentIntoContainerLocked(ctx context.Context, dc c
12821282
api.logger.Error(ctx,"unable to read devcontainer config",slog.Error(err))
12831283
}
12841284

1285-
ifignored {
1285+
ifdcIgnored {
12861286
proc.stop()
12871287
ifproc.agent.ID!=uuid.Nil {
12881288
// If we stop the subagent, we also need to delete it.

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp