Skip to content

Commit c8d293f

Browse files
committed
fix: scoping
1 parent 5de5235 commit c8d293f

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

cmd/root.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,8 +162,8 @@ func checkForUpdate(ctx context.Context, currentVersion, artifactArch string, cm
162162

163163
wf, _, _ := utils.GetWorkflow()
164164

165-
// If a workflow file is present and specifies that the speakeasyVersion is "latest", don't display update notifications as it will be automatically updated when the command is run.
166-
if wf != nil && wf.SpeakeasyVersion.String() == "latest" {
165+
// If we are running the run command and a workflow file is present and specifies that the speakeasyVersion is "latest", don't display update notifications as it will be automatically updated when the command is run.
166+
if cmd.Name() == "run" && wf != nil && wf.SpeakeasyVersion.String() == "latest" {
167167
return
168168
}
169169

0 commit comments

Comments
 (0)