diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2019-03-07 22:53:47 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-07 22:53:47 +0100 |
commit | 054bbb3da21b2c76374eb921cba862adb8d5a0b3 (patch) | |
tree | 61e4ea5e735631b6e947ca00884588ca184e8ab6 /app/serializers/activitypub | |
parent | 75cb93676b1dd41d3e47f62466c0c6430691a990 (diff) |
Immediately display poll results to poll author (#10187)
* Immediately display poll results to poll author * Refactor Poll#loaded_options and add Poll#voted? to improve DRYness
Diffstat (limited to 'app/serializers/activitypub')
-rw-r--r-- | app/serializers/activitypub/note_serializer.rb | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/app/serializers/activitypub/note_serializer.rb b/app/serializers/activitypub/note_serializer.rb index 3a9e388a5..553f333d8 100644 --- a/app/serializers/activitypub/note_serializer.rb +++ b/app/serializers/activitypub/note_serializer.rb @@ -122,11 +122,7 @@ class ActivityPub::NoteSerializer < ActiveModel::Serializer end def poll_options - if !object.poll.expired? && object.poll.hide_totals? - object.poll.unloaded_options - else - object.poll.loaded_options - end + object.poll.loaded_options end def poll_and_multiple? |