mirror of
https://github.com/tiennm99/coolify.git
synced 2026-10-14 10:18:20 +00:00
preview comments
This commit is contained in:
1 parent
cafe9019c1
commit
8dbe3cfe0c
14 files changed
+157
-23
No files matched your search
+1
-2
@@ -100,14 +100,13 @@ Route::post('/source/github/events', function () {
|
||||
if (!$id || !$branch) {
|
||||
return response('Nothing to do. No id or branch found.');
|
||||
}
|
||||
$applications = Application::where('repository_project_id', $id);
|
||||
$applications = Application::where('repository_project_id', $id)->whereRelation('source', 'is_public', false);
|
||||
if ($x_github_event === 'push') {
|
||||
$applications = $applications->where('git_branch', $branch)->get();
|
||||
}
|
||||
if ($x_github_event === 'pull_request') {
|
||||
$applications = $applications->where('git_branch', $base_branch)->get();
|
||||
}
|
||||
|
||||
if ($applications->isEmpty()) {
|
||||
return response('Nothing to do. No applications found.');
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user