From 833ffce2df68ae3b673e230fcb273da5d8c4681f Mon Sep 17 00:00:00 2001 From: ThibG Date: Mon, 4 Mar 2019 22:51:23 +0100 Subject: Store remote votes URI (#10158) * Store remote votes URI * Add spec for accepting remote votes * Make poll vote id generation work the same way as follows --- app/models/poll_vote.rb | 3 +++ 1 file changed, 3 insertions(+) (limited to 'app/models/poll_vote.rb') diff --git a/app/models/poll_vote.rb b/app/models/poll_vote.rb index 57781d616..aec678968 100644 --- a/app/models/poll_vote.rb +++ b/app/models/poll_vote.rb @@ -9,6 +9,7 @@ # choice :integer default(0), not null # created_at :datetime not null # updated_at :datetime not null +# uri :string # class PollVote < ApplicationRecord @@ -20,6 +21,8 @@ class PollVote < ApplicationRecord after_create_commit :increment_counter_cache + delegate :local?, to: :account + private def increment_counter_cache -- cgit