mirror of
https://gh.wpcy.net/https://github.com/discourse/discourse.git
synced 2026-06-19 06:13:40 +08:00
The `ReactionsSerializerHelpers` module was defined inline inside `plugin.rb`'s `after_initialize` block as a top-level constant, and `posts_reaction_loader.rb` referenced it as `::ReactionsSerializerHelpers`. That reference is fragile under autoload/reload — the constant can be missing when the loader is required, raising NameError. Move the helpers into `lib/discourse_reactions/reactions_serializer_helpers.rb`, namespace them under `DiscourseReactions::`, and update all call sites. The two previously-separate `module ReactionsSerializerHelpers` fragments are merged into one module with no logic changes. |
||
|---|---|---|
| .. | ||
| engine.rb | ||
| guardian_extension.rb | ||
| migration_report.rb | ||
| notification_extension.rb | ||
| post_action_extension.rb | ||
| post_alerter_extension.rb | ||
| post_extension.rb | ||
| post_reactions_query.rb | ||
| posts_reaction_loader.rb | ||
| reactions_serializer_helpers.rb | ||
| topic_view_posts_serializer_extension.rb | ||
| topic_view_serializer_extension.rb | ||