DEV: Add poll:voted event (#12070)
This commit is contained in:
parent
46e7d303b1
commit
5d8673321f
|
@ -962,6 +962,8 @@ export default createWidget("discourse-poll", {
|
|||
})
|
||||
.then(({ poll }) => {
|
||||
attrs.poll.setProperties(poll);
|
||||
this.appEvents.trigger("poll:voted", poll, attrs.post, attrs.vote);
|
||||
|
||||
if (attrs.poll.get("results") !== "on_close") {
|
||||
state.showResults = true;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue