Add event for when "Reply" is clicked
This is useful by analytics libraries or other code that wants to track when replies are begun. A new event: `page:compose-reply` is fired with the topic.
This commit is contained in:
parent
847f48a9d0
commit
5c9acfec1d
|
@ -471,6 +471,8 @@ export default Ember.Controller.extend(bufferedProperty("model"), {
|
||||||
const quoteState = this.quoteState;
|
const quoteState = this.quoteState;
|
||||||
const postStream = this.get("model.postStream");
|
const postStream = this.get("model.postStream");
|
||||||
|
|
||||||
|
this.appEvents.trigger("page:compose-reply", topic);
|
||||||
|
|
||||||
if (!postStream || !topic || !topic.get("details.can_create_post")) {
|
if (!postStream || !topic || !topic.get("details.can_create_post")) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue