mirror of
https://github.com/discourse/discourse.git
synced 2024-11-23 02:19:27 +08:00
DEV: Fix fabricator
deprecations (#17658)
This commit is contained in:
parent
59686c1cb8
commit
23a267c75d
|
@ -28,7 +28,7 @@ Fabricator(:private_category_with_definition, from: :private_category) do
|
|||
end
|
||||
|
||||
Fabricator(:link_category, from: :category) do
|
||||
before_validation { |category, transients| category.topic_featured_link_allowed = true }
|
||||
before_create { |category, transients| category.topic_featured_link_allowed = true }
|
||||
end
|
||||
|
||||
Fabricator(:mailinglist_mirror_category, from: :category) do
|
||||
|
|
|
@ -7,7 +7,7 @@ Fabricator(:post) do
|
|||
post_type Post.types[:regular]
|
||||
|
||||
# Fabrication bypasses PostCreator, for performance reasons, where the counts are updated so we have to handle this manually here.
|
||||
after_save do |post, _transients|
|
||||
after_create do |post, _transients|
|
||||
UserStatCountUpdater.increment!(post)
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue
Block a user