From 7f0682f4f23150890ec93452bac0da21c9d5938a Mon Sep 17 00:00:00 2001 From: Mark VanLandingham Date: Fri, 28 Apr 2023 12:11:53 -0500 Subject: [PATCH] DEV: Wrap remote theme update in transaction (#21302) --- lib/tasks/themes.rake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/tasks/themes.rake b/lib/tasks/themes.rake index 3e27bd3387b..351ba4b5550 100644 --- a/lib/tasks/themes.rake +++ b/lib/tasks/themes.rake @@ -62,7 +62,7 @@ def update_themes .includes(:remote_theme) .where(enabled: true, auto_update: true) .find_each do |theme| - begin + theme.transaction do remote_theme = theme.remote_theme next if remote_theme.blank? || remote_theme.remote_url.blank?