diff --git a/go/libraries/doltcore/sqle/dprocedures/dolt_remote.go b/go/libraries/doltcore/sqle/dprocedures/dolt_remote.go index 746405ee89..b9c8dc1d53 100644 --- a/go/libraries/doltcore/sqle/dprocedures/dolt_remote.go +++ b/go/libraries/doltcore/sqle/dprocedures/dolt_remote.go @@ -146,7 +146,7 @@ func removeRemote(ctx *sql.Context, dbd env.DbData[*sql.Context], apr *argparser if err != nil { return fmt.Errorf("failed to get branches: %w", err) } - + var branchesToUpdate []string branches.Iter(func(branchName string, config env.BranchConfig) bool { if config.Remote == remote.Name { @@ -154,7 +154,7 @@ func removeRemote(ctx *sql.Context, dbd env.DbData[*sql.Context], apr *argparser } return true }) - + // Clear the remote tracking for these branches by updating their configs for _, branchName := range branchesToUpdate { currentConfig, _ := branches.Get(branchName)