Skip to content

Commit 43a1ba1

Browse files
authored
fix(api): workflow push from repository (#6330)
1 parent c941171 commit 43a1ba1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

engine/api/workflow/dao.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1301,7 +1301,7 @@ func Push(ctx context.Context, db *gorp.DbMap, store cache.Store, proj *sdk.Proj
13011301
return nil, nil, nil, nil, sdk.WithStack(sdk.ErrWorkflowAlreadyAsCode)
13021302
}
13031303
// Force option will not allow to change the repository of an existing workflow
1304-
if opts != nil && opts.FromRepository != oldWf.FromRepository {
1304+
if opts != nil && opts.FromRepository != "" && opts.FromRepository != oldWf.FromRepository {
13051305
return nil, nil, nil, nil, sdk.WithStack(sdk.ErrWorkflowAlreadyAsCode)
13061306
}
13071307
}

0 commit comments

Comments
 (0)