Просмотр исходного кода

update overwrite method to read from db on return

Alexander Belanger 4 лет назад
Родитель
Сommit
801f61a2fc
1 измененных файлов с 2 добавлено и 7 удалено
  1. 2 7
      internal/repository/gorm/auth.go

+ 2 - 7
internal/repository/gorm/auth.go

@@ -1419,13 +1419,8 @@ func (repo *AzureIntegrationRepository) OverwriteAzureIntegration(
 		}
 		}
 	}
 	}
 
 
-	err = repo.DecryptAzureIntegrationData(az, repo.key)
-
-	if err != nil {
-		return nil, err
-	}
-
-	return az, nil
+	// perform another read
+	return repo.ReadAzureIntegration(az.ProjectID, az.ID)
 }
 }
 
 
 // ReadAzureIntegration finds a Azure auth mechanism by id
 // ReadAzureIntegration finds a Azure auth mechanism by id