Browse Source

refactor: remove redundant routing

pull/944/head
natdeanlewissoftwire 3 years ago
parent
commit
8a1166c129
  1. 2
      app/models/form.rb

2
app/models/form.rb

@ -60,8 +60,6 @@ class Form
page_index = page_ids.index(page.id) page_index = page_ids.index(page.id)
page_id = if page.id.include?("value_check") && log[page.questions[0].id] == 1 && page.routed_to?(log, current_user) page_id = if page.id.include?("value_check") && log[page.questions[0].id] == 1 && page.routed_to?(log, current_user)
previous_page(page_ids, page_index, log, current_user) previous_page(page_ids, page_index, log, current_user)
elsif page.id == ("person_2_known")
"person_2_age"
else else
page_ids[page_index + 1] page_ids[page_index + 1]
end end

Loading…
Cancel
Save