This commit is contained in:
rinsuki 2019-03-07 09:49:42 +09:00 committed by Eugen Rochko
parent 4f2eb43d8a
commit ed3d470069

View file

@ -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><