diff --git a/app/config/collections.php b/app/config/collections.php index 200a972f64..80df6d6011 100644 --- a/app/config/collections.php +++ b/app/config/collections.php @@ -566,6 +566,17 @@ $collections = [ 'array' => false, 'filters' => [] ], + [ + '$id' => ID::custom('vcsInstallationInternalId'), + 'type' => Database::VAR_STRING, + 'format' => '', + 'size' => Database::LENGTH_KEY, + 'signed' => true, + 'required' => true, + 'default' => null, + 'array' => false, + 'filters' => [] + ], [ '$id' => ID::custom('projectId'), 'type' => Database::VAR_STRING, diff --git a/app/controllers/api/functions.php b/app/controllers/api/functions.php index 19623a7c54..39bb9f3863 100644 --- a/app/controllers/api/functions.php +++ b/app/controllers/api/functions.php @@ -533,6 +533,7 @@ App::put('/v1/functions/:functionId') Query::limit(100), ]); $vcsInstallationsId = $vcsInstallations->getId(); + $vcsInstallationInternalId = $vcsInstallations->getInternalId(); //Add document in VCS map collection $vcs_repos = new Document([ @@ -543,6 +544,7 @@ App::put('/v1/functions/:functionId') Permission::delete(Role::any()), ], 'vcsInstallationId' => $vcsInstallationsId, + 'vcsInstallationInternalId' => $vcsInstallationInternalId, 'projectId' => $project->getId(), 'projectInternalId' => $projectInternalId, 'repositoryId' => $repositoryId,