This commit is contained in:
Elio Bischof 2023-07-04 16:16:38 +02:00
parent ecdb5d4012
commit d5c40ce7d2
No known key found for this signature in database
GPG Key ID: 7B383FDE4DDBF1BD
2 changed files with 5 additions and 5 deletions

View File

@ -3,7 +3,6 @@ package integration
import (
"context"
"fmt"
"github.com/zitadel/zitadel/pkg/grpc/system"
"testing"
"time"
@ -21,6 +20,7 @@ import (
mgmt "github.com/zitadel/zitadel/pkg/grpc/management"
object "github.com/zitadel/zitadel/pkg/grpc/object/v2alpha"
session "github.com/zitadel/zitadel/pkg/grpc/session/v2alpha"
"github.com/zitadel/zitadel/pkg/grpc/system"
user "github.com/zitadel/zitadel/pkg/grpc/user/v2alpha"
)

View File

@ -88,7 +88,10 @@ func (q *Queries) SearchMilestones(ctx context.Context, instanceIDs []string, qu
if err != nil {
return nil, err
}
if err := rows.Err(); err != nil {
if err = rows.Close(); err != nil {
return nil, errors.ThrowInternal(err, "QUERY-CK9mI", "Errors.Query.CloseRows")
}
if err = rows.Err(); err != nil {
return nil, errors.ThrowInternal(err, "QUERY-asLsI", "Errors.Internal")
}
milestones.LatestSequence, err = q.latestSequence(ctx, milestonesTable)
@ -131,9 +134,6 @@ func prepareMilestonesQuery(ctx context.Context, db prepareDatabase) (sq.SelectB
m.PushedDate = pushedDate.Time
milestones = append(milestones, m)
}
if err := rows.Close(); err != nil {
return nil, errors.ThrowInternal(err, "QUERY-CK9mI", "Errors.Query.CloseRows")
}
return &Milestones{
Milestones: milestones,
SearchResponse: SearchResponse{