mirror of
https://github.com/mastodon/mastodon.git
synced 2024-08-20 21:08:15 -07:00
Fix vote-after-expiration not showing error, count vote as interaction (#10352)
This commit is contained in:
parent
555c4e11ba
commit
9d0573f574
1 changed files with 2 additions and 2 deletions
|
@ -11,14 +11,14 @@ class VoteService < BaseService
|
|||
@choices = choices
|
||||
@votes = []
|
||||
|
||||
return if @poll.expired?
|
||||
|
||||
ApplicationRecord.transaction do
|
||||
@choices.each do |choice|
|
||||
@votes << @poll.votes.create!(account: @account, choice: choice)
|
||||
end
|
||||
end
|
||||
|
||||
ActivityTracker.increment('activity:interactions')
|
||||
|
||||
if @poll.account.local?
|
||||
distribute_poll!
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue