From 9e1b3b009743b1c9cea5144c0b78af5bd1f9cd3c Mon Sep 17 00:00:00 2001 From: David Gay Date: Wed, 7 Jul 2021 22:40:34 -0400 Subject: Fix bug causing game to be hard-locked unplayable as a result of attempting to do any activity which has no skill requirements --- app/views/application/_timer.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app') diff --git a/app/views/application/_timer.html.erb b/app/views/application/_timer.html.erb index de82546..ea710e3 100644 --- a/app/views/application/_timer.html.erb +++ b/app/views/application/_timer.html.erb @@ -17,7 +17,7 @@ <% required_character_skills = current_char.activity.whatnot[:requirements]&.filter_map { |r| current_char.character_skills.find_by(skill: Skill.find_by_gid(r[:gid])) if r[:type] == "skill" } %>
- <% required_character_skills.each do |cs| %> + <% required_character_skills&.each do |cs| %>
<%= cs.skill.name %> level <%= cs.level %>
<%= cs.xp_to_next_level %> XP to next level
-- cgit v1.2.3