diff options
author | rinsuki <428rinsuki+git@gmail.com> | 2019-03-07 09:49:42 +0900 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2019-03-07 01:49:42 +0100 |
commit | f44091d6535463e08a90dbf3d108540bf587cec1 (patch) | |
tree | 2a11e0b0c815f65aa684027234740b97ae0b10c0 | |
parent | 96f905f40913b915496039d188297a7949b1a6db (diff) |
Fix #10202 (#10203)
-rw-r--r-- | app/views/stream_entries/_poll.html.haml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/views/stream_entries/_poll.html.haml b/app/views/stream_entries/_poll.html.haml index c7e5e0c63..dad04b79c 100644 --- a/app/views/stream_entries/_poll.html.haml +++ b/app/views/stream_entries/_poll.html.haml @@ -7,7 +7,7 @@ - options.each do |option| %li - if show_results - - percent = 100 * option.votes_count / poll.votes_count + - percent = poll.votes_count > 0 ? 100 * option.votes_count / poll.votes_count : 0 %span.poll__chart{ style: "width: #{percent}%" } %label.poll__text>< |