|
@ -7,6 +7,8 @@ class VoteService < BaseService |
|
|
include Lockable |
|
|
include Lockable |
|
|
|
|
|
|
|
|
def call(account, poll, choices) |
|
|
def call(account, poll, choices) |
|
|
|
|
|
return if choices.empty? |
|
|
|
|
|
|
|
|
authorize_with account, poll, :vote? |
|
|
authorize_with account, poll, :vote? |
|
|
|
|
|
|
|
|
@account = account |
|
|
@account = account |
|
|