DEV: Wrap remote theme update in transaction (#21302)

This commit is contained in:
Mark VanLandingham 2023-04-28 12:11:53 -05:00 committed by GitHub
parent 290bd975c5
commit 7f0682f4f2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -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?