mirror of
https://github.com/discourse/discourse.git
synced 2025-05-22 02:41:13 +08:00
FEATURE: Add user to topic_tags_changed event (#28714)
* FEATURE: Add user to topic_tags_changed event Add user to topic_tags_changed event context Update automation plugin with new arguments in event Update tests for new arguments relates to https://github.com/discourse/discourse-chat-integration/pull/214 * DEV: change variable name for better readability changed `tags` to be payload and used `values_at` to get the values of the keys
This commit is contained in:
@ -218,7 +218,7 @@ module DiscourseAutomation
|
||||
end
|
||||
end
|
||||
|
||||
def self.handle_topic_tags_changed(topic, old_tag_names, new_tag_names)
|
||||
def self.handle_topic_tags_changed(topic, old_tag_names, new_tag_names, user)
|
||||
name = DiscourseAutomation::Triggers::TOPIC_TAGS_CHANGED
|
||||
|
||||
DiscourseAutomation::Automation
|
||||
@ -248,6 +248,7 @@ module DiscourseAutomation
|
||||
"topic" => topic,
|
||||
"removed_tags" => removed_tags,
|
||||
"added_tags" => added_tags,
|
||||
"user" => user,
|
||||
"placeholders" => {
|
||||
"topic_url" => topic.relative_url,
|
||||
"topic_title" => topic.title,
|
||||
|
Reference in New Issue
Block a user