Skip to content

Commit

Permalink
Merge pull request #3740 from marcrohloff/fix-rails-61-deprecations
Browse files Browse the repository at this point in the history
Fix rails 61 deprecations
  • Loading branch information
aldesantis authored Aug 24, 2020
2 parents 7c1f2e6 + 91dbbc6 commit 430c621
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion core/app/models/spree/taxon.rb
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ def permalink_part=(value)

def touch_ancestors_and_taxonomy
# Touches all ancestors at once to avoid recursive taxonomy touch, and reduce queries.
self.class.where(id: ancestors.pluck(:id)).update_all(updated_at: Time.current)
self.class.default_scoped.where(id: ancestors.pluck(:id)).update_all(updated_at: Time.current)
# Have taxonomy touch happen in #touch_ancestors_and_taxonomy rather than association option in order for imports to override.
taxonomy.try!(:touch)
end
Expand Down
5 changes: 2 additions & 3 deletions core/lib/spree/testing_support/dummy_app.rb
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,8 @@ class Application < ::Rails::Application
config.active_support.deprecation = :stderr
config.secret_key_base = 'SECRET_TOKEN'

unless RAILS_6_OR_ABOVE
config.active_record.sqlite3.represent_boolean_as_integer = true
end
config.action_mailer.delivery_job = "ActionMailer::MailDeliveryJob" if RAILS_6_OR_ABOVE
config.active_record.sqlite3.represent_boolean_as_integer = true unless RAILS_6_OR_ABOVE

config.storage_path = Rails.root.join('tmp', 'storage')

Expand Down

0 comments on commit 430c621

Please sign in to comment.