From c8936a3c83a15cb49cff0d41b71dc8df96e6a8af Mon Sep 17 00:00:00 2001 From: Arnaud Levy <contact@arnaudlevy.com> Date: Tue, 6 Feb 2024 08:22:46 +0100 Subject: [PATCH] fix --- app/models/communication/website/with_screenshot.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/app/models/communication/website/with_screenshot.rb b/app/models/communication/website/with_screenshot.rb index 46869832f..780847cc3 100644 --- a/app/models/communication/website/with_screenshot.rb +++ b/app/models/communication/website/with_screenshot.rb @@ -8,6 +8,7 @@ module Communication::Website::WithScreenshot def screenshot! return if url.blank? screenshot_url = Screenshot.capture(url) + return if screenshot_url.blank? downloaded_image = URI.open(screenshot_url) self.screenshot.attach io: downloaded_image, filename: "screenshot.png" -- GitLab