Fix the show_votes? method again

This commit is contained in:
Michael Ball 2021-05-04 18:22:38 -07:00
parent 6965da9ece
commit ceeab39e3f

View file

@ -110,15 +110,12 @@ class Program < ApplicationRecord
end
##
# Checks if blind_voting is enabled and if voting period is over
# Checks if blind_voting is enabled OR if voting period is over
# ====Returns
# * +true+ -> If we can show voting details
# * +false+ -> If we cannot show voting details
def show_voting?
return true unless blind_voting
# TODO-SNAPCON: UPDATE TESTS
# Time.current > voting_end_date
!blind_voting || Time.current > voting_end_date
end
##