Drop halt_callback_chains_on_return_false
ActiveSupport.halt_callback_chains_on_return_false= is deprecated and will be removed in Rails 5.2. Stop using it and return `throw(:abort)` instead in the callbacks which need it.
This commit is contained in:
parent
b3716985f0
commit
a8d2f8caa4
4 changed files with 1 additions and 7 deletions
|
|
@ -1120,7 +1120,6 @@ class Conference < ApplicationRecord
|
||||||
#
|
#
|
||||||
def create_email_settings
|
def create_email_settings
|
||||||
build_email_settings
|
build_email_settings
|
||||||
true
|
|
||||||
end
|
end
|
||||||
|
|
||||||
##
|
##
|
||||||
|
|
|
||||||
|
|
@ -211,7 +211,6 @@ class Program < ApplicationRecord
|
||||||
EventType.create(title: 'Workshop', length: 60, color: '#0000FF', description: 'Interactive hands-on practice',
|
EventType.create(title: 'Workshop', length: 60, color: '#0000FF', description: 'Interactive hands-on practice',
|
||||||
minimum_abstract_length: 0,
|
minimum_abstract_length: 0,
|
||||||
maximum_abstract_length: 500, program_id: id)
|
maximum_abstract_length: 500, program_id: id)
|
||||||
true
|
|
||||||
end
|
end
|
||||||
|
|
||||||
##
|
##
|
||||||
|
|
@ -227,7 +226,6 @@ class Program < ApplicationRecord
|
||||||
DifficultyLevel.create(title: 'Hard',
|
DifficultyLevel.create(title: 'Hard',
|
||||||
description: 'Events require expert knowledge of the topic.',
|
description: 'Events require expert knowledge of the topic.',
|
||||||
color: '#EF6E69', program_id: id)
|
color: '#EF6E69', program_id: id)
|
||||||
true
|
|
||||||
end
|
end
|
||||||
|
|
||||||
##
|
##
|
||||||
|
|
|
||||||
|
|
@ -18,6 +18,6 @@ class Role < ApplicationRecord
|
||||||
|
|
||||||
# Needed to ensure that removing all user from role doesn't remove role.
|
# Needed to ensure that removing all user from role doesn't remove role.
|
||||||
def cancel
|
def cancel
|
||||||
false
|
throw(:abort)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
||||||
|
|
@ -20,6 +20,3 @@ ActiveSupport.to_time_preserves_timezone = false
|
||||||
|
|
||||||
# Require `belongs_to` associations by default. Previous versions had false.
|
# Require `belongs_to` associations by default. Previous versions had false.
|
||||||
Rails.application.config.active_record.belongs_to_required_by_default = false
|
Rails.application.config.active_record.belongs_to_required_by_default = false
|
||||||
|
|
||||||
# Do not halt callback chains when a callback returns false. Previous versions had true.
|
|
||||||
ActiveSupport.halt_callback_chains_on_return_false = true
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue