Skip to content

Commit

Permalink
remove redirect for setup wazard
Browse files Browse the repository at this point in the history
  • Loading branch information
Thomas EUDE authored and Thomas EUDE committed Dec 2, 2023
1 parent 5e44548 commit faa8c11
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions lib/wicked/wizard.rb
Original file line number Diff line number Diff line change
Expand Up @@ -49,16 +49,10 @@ def wizard_value(step_name)
@wicked_redirect_params = nil
end

private def check_redirect_to_first_last!(step)
redirect_to wizard_path(steps.first) if step.to_s == Wicked::FIRST_STEP
redirect_to wizard_path(steps.last) if step.to_s == Wicked::LAST_STEP
end

private def setup_step_from(the_step)
return if steps.nil?

the_step ||= steps.first
check_redirect_to_first_last!(the_step)

valid_steps = steps + self.class::PROTECTED_STEPS
resolved_step = valid_steps.detect { |stp| stp.to_s == the_step }
Expand Down

0 comments on commit faa8c11

Please sign in to comment.