From 5f5d597c59b1553489691bc114b1962670132589 Mon Sep 17 00:00:00 2001 From: Maycon Santos Date: Thu, 26 Jun 2025 13:54:04 +0200 Subject: [PATCH] fix GetSetupKeyByID --- management/server/store/sql_store.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/management/server/store/sql_store.go b/management/server/store/sql_store.go index 2f8913c82..c0f9b382a 100644 --- a/management/server/store/sql_store.go +++ b/management/server/store/sql_store.go @@ -1901,8 +1901,7 @@ func (s *SqlStore) GetAccountSetupKeys(ctx context.Context, lockStrength Locking func (s *SqlStore) GetSetupKeyByID(ctx context.Context, lockStrength LockingStrength, accountID, setupKeyID string) (*types.SetupKey, error) { tx := s.getTXWithLockStrength(lockStrength) var setupKey *types.SetupKey - result := tx.Clauses(clause.Locking{Strength: string(lockStrength)}). - First(&setupKey, accountAndIDQueryCondition, accountID, setupKeyID) + result := tx.First(&setupKey, accountAndIDQueryCondition, accountID, setupKeyID) if err := result.Error; err != nil { if errors.Is(err, gorm.ErrRecordNotFound) { return nil, status.NewSetupKeyNotFoundError(setupKeyID)