Add initializer included in acts-as-taggable-on 10.0.0
Similar to what we do with other gems, we add the commented code.
This commit is contained in:
@@ -1,3 +1,12 @@
|
||||
ActsAsTaggableOn.setup do |config|
|
||||
# This works because the classes where the base class is a concern, Tag and Tagging
|
||||
# are autoloaded, and won't be started until after the initializers run. The value
|
||||
# must be a String, as the Rails Zeitwerk autoloader will not allow models to be
|
||||
# referenced at initialization time.
|
||||
#
|
||||
# config.base_class = "ApplicationRecord"
|
||||
end
|
||||
|
||||
module ActsAsTaggableOn
|
||||
Tagging.class_eval do
|
||||
after_create :increment_tag_custom_counter
|
||||
|
||||
Reference in New Issue
Block a user