Fix not being able to vote (#13490)
Fix regression introduced by ab8d7c0680
This commit is contained in:
parent
89077fb657
commit
e12a5635da
2 changed files with 7 additions and 4 deletions
|
@ -2,7 +2,7 @@ import { connect } from 'react-redux';
|
|||
import { debounce } from 'lodash';
|
||||
|
||||
import Poll from 'mastodon/components/poll';
|
||||
import { fetchPoll } from 'mastodon/actions/polls';
|
||||
import { fetchPoll, vote } from 'mastodon/actions/polls';
|
||||
|
||||
const mapDispatchToProps = (dispatch, { pollId }) => ({
|
||||
refresh: debounce(
|
||||
|
@ -12,6 +12,10 @@ const mapDispatchToProps = (dispatch, { pollId }) => ({
|
|||
1000,
|
||||
{ leading: true },
|
||||
),
|
||||
|
||||
onVote (choices) {
|
||||
dispatch(vote(pollId, choices));
|
||||
},
|
||||
});
|
||||
|
||||
const mapStateToProps = (state, { pollId }) => ({
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue