From 2da4e9a274d7d19c0de24049eb3af9fbb3bc16b7 Mon Sep 17 00:00:00 2001 From: peaklabs-dev <122374094+peaklabs-dev@users.noreply.github.com> Date: Mon, 9 Dec 2024 12:08:27 +0100 Subject: [PATCH] feat: enable success messages again --- app/Jobs/ApplicationDeploymentJob.php | 2 +- app/Jobs/DatabaseBackupJob.php | 4 +++- app/Models/Server.php | 4 ++-- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/app/Jobs/ApplicationDeploymentJob.php b/app/Jobs/ApplicationDeploymentJob.php index 04e71c4e3..6b677fa0e 100644 --- a/app/Jobs/ApplicationDeploymentJob.php +++ b/app/Jobs/ApplicationDeploymentJob.php @@ -2409,7 +2409,7 @@ COPY ./nginx.conf /etc/nginx/conf.d/default.conf"); if (! $this->only_this_server) { $this->deploy_to_additional_destinations(); } - //$this->application->environment->project->team?->notify(new DeploymentSuccess($this->application, $this->deployment_uuid, $this->preview)); + $this->application->environment->project->team?->notify(new DeploymentSuccess($this->application, $this->deployment_uuid, $this->preview)); } } diff --git a/app/Jobs/DatabaseBackupJob.php b/app/Jobs/DatabaseBackupJob.php index ee702202f..06aec5e49 100644 --- a/app/Jobs/DatabaseBackupJob.php +++ b/app/Jobs/DatabaseBackupJob.php @@ -306,7 +306,9 @@ class DatabaseBackupJob implements ShouldBeEncrypted, ShouldQueue if ($this->backup->save_s3) { $this->upload_to_s3(); } - //$this->team?->notify(new BackupSuccess($this->backup, $this->database, $database)); + + $this->team->notify(new BackupSuccess($this->backup, $this->database, $database)); + $this->backup_log->update([ 'status' => 'success', 'message' => $this->backup_output, diff --git a/app/Models/Server.php b/app/Models/Server.php index 6dfb0a4a1..cc8211789 100644 --- a/app/Models/Server.php +++ b/app/Models/Server.php @@ -1042,7 +1042,7 @@ $schema://$host { $this->unreachable_notification_sent = false; $this->save(); $this->refresh(); - // $this->team->notify(new Reachable($this)); + $this->team->notify(new Reachable($this)); } public function sendUnreachableNotification() @@ -1050,7 +1050,7 @@ $schema://$host { $this->unreachable_notification_sent = true; $this->save(); $this->refresh(); - // $this->team->notify(new Unreachable($this)); + $this->team->notify(new Unreachable($this)); } public function validateConnection(bool $justCheckingNewKey = false)