Remove tasks to upgrade to version 1.1
These tasks are not needed for new installations, and in existing installations they've already been executed when upgrading to version 1.1. One of them also raises a warning in Rails 5.2: DEPRECATION WARNING: Dangerous query method (method whose arguments are used as raw SQL) called with non-attribute argument(s): "MIN(id) as id". Non-attribute arguments will be disallowed in Rails 6.0. This method should not be called with user-provided values, such as request parameters or model attributes. Known-safe values can be passed by wrapping them in Arel.sql()
This commit is contained in:
@@ -10,15 +10,4 @@ namespace :budgets do
|
||||
Budget.last.email_unselected
|
||||
end
|
||||
end
|
||||
|
||||
desc "Update investments original_heading_id with current heading_id"
|
||||
task set_original_heading_id: :environment do
|
||||
ApplicationLogger.new.info "Setting original_heading_id to investments"
|
||||
Budget::Investment.find_each do |investment|
|
||||
unless investment.original_heading_id.present?
|
||||
investment.update_column(:original_heading_id, investment.heading_id)
|
||||
end
|
||||
print "."
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user