This commit is contained in:
Andras Bacsai committed 2023-05-30 15:05:27 +00:00
1 parent ca777384eb
commit 3d4e985aa6
2 files changed
+6 -6

No files matched your search

@@ -69,11 +69,11 @@ class Previews extends Component
ray('Stopping container: ' . $container_name);
instant_remote_process(["docker rm -f $container_name"], $this->application->destination->server, throwError: false);
dispatch(new ContainerStatusJob(
application: $this->application,
container_name: $container_name,
pull_request_id: $pull_request_id
));
$found = ApplicationPreview::where('application_id', $this->application->id)->where('pull_request_id', $pull_request_id)->first();
if ($found) {
$found->delete();
}
$this->application->refresh();
} catch (\Throwable $th) {
return general_error_handler($th, $this);
}