app/controllers/sign_ups_controller.rb
# `assert_year_matches_route` should prevent visitors from, for example,
# using the 2012 registration form to create a 2011 user.
`assert_year_matches_route` should prevent visitors from, for example,
using the 2012 registration form to create a 2011 user.
` assert_year_matches_route ` should prevent visitors from for example using the 2012 registration form to create a 2011 user .
def assert_year_matches_route
    if params_contains_user_attr(:year) && params[:user][:year].to_i != @year.year
      raise "Invalid year in params: Expected #{@year.year}, found #{params[:user][:year]}"
    end
  end
def assert_year_matches_route if params_contains_user_attr ( :year ) && params [ :user ] [ :year ] . to_i != @year . year raise "Invalid year in params: Expected #{@year.year}, found #{params[:user][:year]}" end end
`assert_year_matches_route` should prevent visitors from, for example,
using the 2012 registration form to create a 2011 user.
` assert_year_matches_route ` should prevent visitors from for example using the 2012 registration form to create a 2011 user .