diff --git a/app/Models/Application.php b/app/Models/Application.php index c4a6a18e2..3d0b92aaf 100644 --- a/app/Models/Application.php +++ b/app/Models/Application.php @@ -459,7 +459,7 @@ class Application extends BaseModel } public function get_last_successful_deployment() { - return ApplicationDeploymentQueue::where('application_id', $this->id)->where('status', 'finished')->orderBy('created_at', 'desc')->first(); + return ApplicationDeploymentQueue::where('application_id', $this->id)->where('status', 'finished')->where('pull_request_id', 0)->orderBy('created_at', 'desc')->first(); } public function get_last_days_deployments() {