lib/PrivateMethods.rb in PlayRockPaperScissorsGame-2.6.2 vs lib/PrivateMethods.rb in PlayRockPaperScissorsGame-2.6.3
- old
+ new
@@ -9,9 +9,11 @@
choice = gets.chomp.downcase
if Constants::NTRY_TO_SYM.key?(choice)
return Constants::NTRY_TO_SYM[choice]
elsif choice != Constants::VALID_ENTRIES
puts ColorizedString["That entry is invalid. Please re-enter."].colorize(:red)
+ else
+ # do nothing
end
# # one may also do this:
# case
# when Constants::NTRY_TO_SYM.key?(choice)
# return Constants::NTRY_TO_SYM[choice]