mirror of
https://github.com/appwrite/appwrite.git
synced 2026-05-26 13:51:13 +00:00
Update app/controllers/api/vcs.php
Co-authored-by: Matej Bačo <matejbacocom@gmail.com>
This commit is contained in:
@@ -296,7 +296,7 @@ $createGitDeployments = function (GitHub $github, string $providerInstallationId
|
||||
$branchPrefix = substr($providerBranch, 0, 16);
|
||||
if (strlen($providerBranch) > 16) {
|
||||
$remainingChars = substr($providerBranch, 16);
|
||||
$branchPrefix .= substr(hash('sha256', $remainingChars), 0, 7);
|
||||
$branchPrefix .= '-' . substr(hash('sha256', $remainingChars), 0, 7);
|
||||
}
|
||||
$resourceProjectHash = substr(hash('sha256', $resource->getId() . $project->getId()), 0, 7);
|
||||
$domain = "branch-{$branchPrefix}-{$resourceProjectHash}.{$sitesDomain}";
|
||||
|
||||
Reference in New Issue
Block a user